diff options
Diffstat (limited to 'source4/lib/events/events_liboop.c')
-rw-r--r-- | source4/lib/events/events_liboop.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source4/lib/events/events_liboop.c b/source4/lib/events/events_liboop.c index 96bdafd956..cc9047b4eb 100644 --- a/source4/lib/events/events_liboop.c +++ b/source4/lib/events/events_liboop.c @@ -101,6 +101,11 @@ static int oop_event_fd_destructor(struct fd_event *fde) if (fde->flags & EVENT_FD_WRITE) oop->cancel_fd(oop, fde->fd, OOP_WRITE); + if (fde->flags & EVENT_FD_AUTOCLOSE) { + close(fde->fd); + fde->fd = -1; + } + return 0; } |