Skip to content

Commit

Permalink
get_key_material_https: removed bogus free() call
Browse files Browse the repository at this point in the history
The get_key_material_https() function error code path had a bogus
free() call, either resulting in double-free or free() of undefined
pointer.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Ahelenia Ziemia<C5><84>ska <nabijaczleweli@nabijaczleweli.xyz>
Co-authored-by: Harry Sintonen <sintonen@iki.fi>
Signed-off-by: Harry Sintonen <sintonen@iki.fi>
Closes openzfs#13198
  • Loading branch information
nabijaczleweli authored Mar 17, 2022
1 parent 7b215d9 commit 0bebcbc
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion lib/libzfs/libzfs_crypto.c
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,6 @@ get_key_material_https(libzfs_handle_t *hdl, const char *uri,
kfdok:
if ((key = fdopen(kfd, "r+")) == NULL) {
ret = errno;
free(path);
(void) close(kfd);
zfs_error_aux(hdl, dgettext(TEXT_DOMAIN,
"Couldn't reopen temporary file: %s"), strerror(ret));
Expand Down

0 comments on commit 0bebcbc

Please sign in to comment.