Skip to content

Commit

Permalink
bhyvectl: don't leak nvlist in send_message
Browse files Browse the repository at this point in the history
Reviewed by:		corvink, markj
MFC after:		1 week
Sponsored by:		vStack
Differential Revision:	https://reviews.freebsd.org/D38900
  • Loading branch information
gusev-vitaliy authored and ckoehne committed Mar 6, 2023
1 parent b64ba24 commit 942525a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion usr.sbin/bhyvectl/bhyvectl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1704,9 +1704,9 @@ send_message(const char *vmname, nvlist_t *nvl)
perror("nvlist_send() failed");
err = errno;
}
done:
nvlist_destroy(nvl);

done:
if (socket_fd >= 0)
close(socket_fd);
return (err);
Expand Down

0 comments on commit 942525a

Please sign in to comment.