Skip to content

Commit aa822e4

Browse files
ryaobehlendorf
authored andcommitted
Fix NULL pointer dereference in zdb
Clang's static analyzer complained that we dereference a NULL pointer in dump_path() if we return 0 when there is an error. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Richard Yao <richard.yao@alumni.stonybrook.edu> Closes #14044
1 parent 09453de commit aa822e4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/zdb/zdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3067,7 +3067,7 @@ open_objset(const char *path, const void *tag, objset_t **osp)
30673067
}
30683068
sa_os = *osp;
30693069

3070-
return (0);
3070+
return (err);
30713071
}
30723072

30733073
static void

0 commit comments

Comments
 (0)