mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-30 00:00:16 +01:00
raw-file: clear POLLOUT before handling
This commit is contained in:
parent
312bb56385
commit
99f7e572ca
1 changed files with 1 additions and 1 deletions
|
@ -31,11 +31,11 @@ rops_handle_POLLIN_raw_file(struct lws_context_per_thread *pt, struct lws *wsi,
|
||||||
int n;
|
int n;
|
||||||
|
|
||||||
if (pollfd->revents & LWS_POLLOUT) {
|
if (pollfd->revents & LWS_POLLOUT) {
|
||||||
n = lws_callback_as_writeable(wsi);
|
|
||||||
if (lws_change_pollfd(wsi, LWS_POLLOUT, 0)) {
|
if (lws_change_pollfd(wsi, LWS_POLLOUT, 0)) {
|
||||||
lwsl_wsi_info(wsi, "failed at set pollfd");
|
lwsl_wsi_info(wsi, "failed at set pollfd");
|
||||||
return LWS_HPI_RET_WSI_ALREADY_DIED;
|
return LWS_HPI_RET_WSI_ALREADY_DIED;
|
||||||
}
|
}
|
||||||
|
n = lws_callback_as_writeable(wsi);
|
||||||
if (n)
|
if (n)
|
||||||
return LWS_HPI_RET_PLEASE_CLOSE_ME;
|
return LWS_HPI_RET_PLEASE_CLOSE_ME;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue