mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-09 00:00:04 +01:00
raw file: drain POLLIN before handling close as needed for pipes
This commit is contained in:
parent
3d8fbdd3ac
commit
e9fd43e041
1 changed files with 2 additions and 1 deletions
|
@ -50,7 +50,8 @@ rops_handle_POLLIN_raw_file(struct lws_context_per_thread *pt, struct lws *wsi,
|
|||
}
|
||||
|
||||
if (pollfd->revents & LWS_POLLHUP)
|
||||
return LWS_HPI_RET_PLEASE_CLOSE_ME;
|
||||
if (!(pollfd->revents & LWS_POLLIN))
|
||||
return LWS_HPI_RET_PLEASE_CLOSE_ME;
|
||||
|
||||
return LWS_HPI_RET_HANDLED;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue