Skip to content

Commit

Permalink
Fix zdb "Memory fault" found on FreeBSD ZTS
Browse files Browse the repository at this point in the history
- reason: nvlist_free() tries to free sth. which isn't allocted
- solution: init this variable with NULL

Signed-off-by: Tino Reichardt <[email protected]>

Closes openzfs#16311
  • Loading branch information
mcmilk committed Jul 9, 2024
1 parent bbe0095 commit 527ba16
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/zdb/zdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -9186,7 +9186,7 @@ main(int argc, char **argv)
char *pname = strdup(target);
const char *value;
nvlist_t *pnvl = NULL;
nvlist_t *vnvl;
nvlist_t *vnvl = NULL;

if (strpbrk(pname, "/@") != NULL)
*strpbrk(pname, "/@") = '\0';
Expand Down

0 comments on commit 527ba16

Please sign in to comment.