Skip to content

Commit

Permalink
Drop disabled knotes in copyout
Browse files Browse the repository at this point in the history
  • Loading branch information
bozzzzo committed Sep 18, 2014
1 parent f3828af commit 6834dc8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions libkqueue/src/windows/platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,11 @@ windows_kevent_copyout(struct kqueue *kq, int nready,
knote_release(kn);
return 0;
}
if (kn->kev.flags & EV_DISABLE) {
dbg_printf("Dropping disabled knote %p", kn);
knote_release(kn);
return 0;
}
filt = &kq->kq_filt[~(kn->kev.filter)];
rv = filt->kf_copyout(eventlist, kn, &iocp_buf);
if (slowpath(rv < 0)) {
Expand Down

0 comments on commit 6834dc8

Please sign in to comment.