diff --git a/src/fdevent_freebsd_kqueue.c b/src/fdevent_freebsd_kqueue.c index 0585cfbf..25728fb2 100644 --- a/src/fdevent_freebsd_kqueue.c +++ b/src/fdevent_freebsd_kqueue.c @@ -100,8 +100,14 @@ static int fdevent_freebsd_kqueue_poll(fdevents *ev, int timeout_ms) { &ts); if (ret == -1) { - fprintf(stderr, "%s.%d: kqueue failed polling: %s\n", - __FILE__, __LINE__, strerror(errno)); + switch(errno) { + case EINTR: + /* we got interrupted, perhaps just a SIGCHLD of a CGI script */ + return 0; + default: + fprintf(stderr, "%s.%d: kqueue failed polling: %s\n", + __FILE__, __LINE__, strerror(errno)); + break; } return ret;