diff --git a/usr.sbin/bhyvectl/bhyvectl.c b/usr.sbin/bhyvectl/bhyvectl.c --- a/usr.sbin/bhyvectl/bhyvectl.c +++ b/usr.sbin/bhyvectl/bhyvectl.c @@ -1707,7 +1707,7 @@ nvlist_destroy(nvl); done: - if (socket_fd > 0) + if (socket_fd >= 0) close(socket_fd); return (err); }