diff options
author | George Melikov <[email protected]> | 2017-02-08 01:02:27 +0300 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2017-02-07 14:02:27 -0800 |
commit | 23d70cdef108005ecf4d862e0af01d08dabbc9c7 (patch) | |
tree | 8af0ff2442871fa26127476539d87579681490a3 /lib/libzfs/libzfs_sendrecv.c | |
parent | bef78122e606945efbf2e08845e7d5e8ead93c3c (diff) |
OpenZFS 6931 - lib/libzfs: cleanup gcc warnings
Authored by: Igor Kozhukhov <[email protected]>
Reviewed by: Matthew Ahrens <[email protected]>
Approved by: Robert Mustacchi <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Ported-by: George Melikov <[email protected]>
OpenZFS-issue: https://www.illumos.org/issues/6931
OpenZFS-commit: https://github.com/openzfs/openzfs/commit/88f61de
Closes #5741
Diffstat (limited to 'lib/libzfs/libzfs_sendrecv.c')
-rw-r--r-- | lib/libzfs/libzfs_sendrecv.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/libzfs/libzfs_sendrecv.c b/lib/libzfs/libzfs_sendrecv.c index c1a09e3a9..e703fd254 100644 --- a/lib/libzfs/libzfs_sendrecv.c +++ b/lib/libzfs/libzfs_sendrecv.c @@ -27,6 +27,7 @@ * All rights reserved * Copyright (c) 2013 Steven Hartland. All rights reserved. * Copyright 2015, OmniTI Computer Consulting, Inc. All rights reserved. + * Copyright 2016 Igor Kozhukhov <[email protected]> */ #include <assert.h> @@ -1325,7 +1326,7 @@ dump_snapshot(zfs_handle_t *zhp, void *arg) pa.pa_parsable = sdd->parsable; if ((err = pthread_create(&tid, NULL, - send_progress_thread, &pa))) { + send_progress_thread, &pa)) != 0) { zfs_close(zhp); return (err); } @@ -1800,7 +1801,7 @@ zfs_send(zfs_handle_t *zhp, const char *fromsnap, const char *tosnap, if (flags->dedup && !flags->dryrun) { featureflags |= (DMU_BACKUP_FEATURE_DEDUP | DMU_BACKUP_FEATURE_DEDUPPROPS); - if ((err = socketpair(AF_UNIX, SOCK_STREAM, 0, pipefd))) { + if ((err = socketpair(AF_UNIX, SOCK_STREAM, 0, pipefd)) != 0) { zfs_error_aux(zhp->zfs_hdl, strerror(errno)); return (zfs_error(zhp->zfs_hdl, EZFS_PIPEFAILED, errbuf)); @@ -1808,7 +1809,7 @@ zfs_send(zfs_handle_t *zhp, const char *fromsnap, const char *tosnap, dda.outputfd = outfd; dda.inputfd = pipefd[1]; dda.dedup_hdl = zhp->zfs_hdl; - if ((err = pthread_create(&tid, NULL, cksummer, &dda))) { + if ((err = pthread_create(&tid, NULL, cksummer, &dda)) != 0) { (void) close(pipefd[0]); (void) close(pipefd[1]); zfs_error_aux(zhp->zfs_hdl, strerror(errno)); |