1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

libwebsocket_service_fd: EAGAIN is harmless, treat like EINTR

Only tested on linux.

Signed-off-by: Alon Levy <alevy@redhat.com>
This commit is contained in:
Alon Levy 2012-10-19 11:21:57 +02:00 committed by Andy Green
parent 0291eb3b95
commit dc93b7f2e7

View file

@ -1993,7 +1993,7 @@ bail3:
if (eff_buf.token_len < 0) {
fprintf(stderr, "Socket read returned %d\n",
eff_buf.token_len);
if (errno != EINTR)
if (errno != EINTR && errno != EAGAIN)
libwebsocket_close_and_free_session(context,
wsi, LWS_CLOSE_STATUS_NOSTATUS);
return 1;