diff --git a/lib/service.c b/lib/service.c index ca0985b1..ec3681b9 100644 --- a/lib/service.c +++ b/lib/service.c @@ -383,7 +383,8 @@ libwebsocket_service_fd(struct libwebsocket_context *context, /* it was the guy we came to service! */ timed_out = 1; /* mark as handled */ - pollfd->revents = 0; + if (pollfd) + pollfd->revents = 0; } } }