diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/tevent/tevent_poll.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/tevent/tevent_poll.c b/lib/tevent/tevent_poll.c index f64dd386f9..0c580e49ee 100644 --- a/lib/tevent/tevent_poll.c +++ b/lib/tevent/tevent_poll.c @@ -57,6 +57,14 @@ struct poll_event_context { static int poll_event_context_destructor(struct poll_event_context *poll_ev) { + struct tevent_fd *fd, *fn; + + for (fd = poll_ev->fresh; fd; fd = fn) { + fn = fd->next; + fd->event_ctx = NULL; + DLIST_REMOVE(poll_ev->fresh, fd); + } + if (poll_ev->signal_fd == -1) { /* * Non-threaded, no signal pipe |