diff options
Diffstat (limited to 'ev_epoll.c')
-rw-r--r-- | ev_epoll.c | 11 |
1 files changed, 3 insertions, 8 deletions
@@ -110,15 +110,10 @@ epoll_destroy (EV_P) static void epoll_fork (EV_P) { - for (;;) - { - epoll_fd = epoll_create (256); - - if (epoll_fd >= 0) - break; + close (epoll_fd); - syserr ("(libev) epoll_create"); - } + while ((epoll_fd = epoll_create (256)) < 0) + syserr ("(libev) epoll_create"); fcntl (epoll_fd, F_SETFD, FD_CLOEXEC); |