aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/zstreamdump/zstreamdump.c
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/zstreamdump/zstreamdump.c')
-rw-r--r--cmd/zstreamdump/zstreamdump.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/cmd/zstreamdump/zstreamdump.c b/cmd/zstreamdump/zstreamdump.c
index 6c7150b10..a2edefa92 100644
--- a/cmd/zstreamdump/zstreamdump.c
+++ b/cmd/zstreamdump/zstreamdump.c
@@ -384,10 +384,12 @@ main(int argc, char *argv[])
if (ferror(send_stream))
perror("fread");
err = nvlist_unpack(buf, sz, &nv, 0);
- if (err)
+ if (err) {
perror(strerror(err));
- nvlist_print(stdout, nv);
- nvlist_free(nv);
+ } else {
+ nvlist_print(stdout, nv);
+ nvlist_free(nv);
+ }
}
break;