aboutsummaryrefslogtreecommitdiff
path: root/cddl/contrib/opensolaris/lib
diff options
context:
space:
mode:
authorSteven Hartland <smh@FreeBSD.org>2013-07-30 20:45:27 +0000
committerSteven Hartland <smh@FreeBSD.org>2013-07-30 20:45:27 +0000
commitb79849e50cf5f1e870b314129e043b9e58a00280 (patch)
treef52179596b77a45580d001f8053bb1f66d5e8252 /cddl/contrib/opensolaris/lib
parent44e362e207d98c5b5c4e5ebfc3bad648fe06c714 (diff)
parentfe8484c3baac99b403effe510b587088640744bb (diff)
downloadsrc-b79849e50cf5f1e870b314129e043b9e58a00280.tar.gz
src-b79849e50cf5f1e870b314129e043b9e58a00280.zip
MFV r253784:
Fix zfs send -D hang after processing requiring a CTRL+C to interrupt due to pthread_join prior to fd close. This was introduced by r251646 (MFV r251644) Illumos ZFS issue: 3909 "zfs send -D" does not work MFC after: 1 day
Notes
Notes: svn path=/head/; revision=253818
Diffstat (limited to 'cddl/contrib/opensolaris/lib')
-rw-r--r--cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c b/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c
index d0eac12016e1..1fc46c24e4ab 100644
--- a/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c
+++ b/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c
@@ -1576,8 +1576,8 @@ zfs_send(zfs_handle_t *zhp, const char *fromsnap, const char *tosnap,
if (tid != 0) {
if (err != 0)
(void) pthread_cancel(tid);
- (void) pthread_join(tid, NULL);
(void) close(pipefd[0]);
+ (void) pthread_join(tid, NULL);
}
if (sdd.cleanup_fd != -1) {
@@ -1613,8 +1613,8 @@ err_out:
VERIFY(0 == close(sdd.cleanup_fd));
if (tid != 0) {
(void) pthread_cancel(tid);
- (void) pthread_join(tid, NULL);
(void) close(pipefd[0]);
+ (void) pthread_join(tid, NULL);
}
return (err);
}