Fix descriptors leak.
PR: bin/191002 Reported by: Ryan Steinmetz Submitted by: mjg
This commit is contained in:
parent
4f66b23341
commit
863dbc940e
@ -228,6 +228,11 @@ wait_for_file_init(int fd)
|
||||
PJDLOG_ASSERT(fd != -1);
|
||||
|
||||
#ifdef HAVE_KQUEUE
|
||||
if (wait_for_file_kq != -1) {
|
||||
close(wait_for_file_kq);
|
||||
wait_for_file_kq = -1;
|
||||
}
|
||||
|
||||
kq = kqueue();
|
||||
if (kq == -1) {
|
||||
pjdlog_errno(LOG_WARNING, "kqueue() failed");
|
||||
|
Loading…
Reference in New Issue
Block a user