Skip to content

Commit

Permalink
Fix typo in check_clones()
Browse files Browse the repository at this point in the history
Run kmem_free() after zap_cursor_fini().

Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Tino Reichardt <[email protected]>
Reviewed-by: Adam Moss <[email protected]>
Signed-off-by: George Amanakis <[email protected]>
Closes openzfs#14702
  • Loading branch information
gamanakis authored Apr 6, 2023
1 parent 8ab674a commit a8a127e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion module/zfs/spa_errlog.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,9 +470,9 @@ static int check_clones(spa_t *spa, uint64_t zap_clone, uint64_t snap_count,
break;
}

zap_cursor_fini(zc);
kmem_free(za, sizeof (*za));
kmem_free(zc, sizeof (*zc));
zap_cursor_fini(zc);

return (error);
}
Expand Down

0 comments on commit a8a127e

Please sign in to comment.