diff --git a/lib/plat/freertos/freertos-service.c b/lib/plat/freertos/freertos-service.c index 773099160..5fdd25669 100644 --- a/lib/plat/freertos/freertos-service.c +++ b/lib/plat/freertos/freertos-service.c @@ -29,7 +29,6 @@ lws_plat_service(struct lws_context *context, int timeout_ms) { int n = _lws_plat_service_tsi(context, timeout_ms, 0); - lws_service_fd_tsi(context, NULL, 0); #if !defined(LWS_AMAZON_RTOS) esp_task_wdt_reset(); #endif @@ -177,11 +176,8 @@ _lws_plat_service_tsi(struct lws_context *context, int timeout_ms, int tsi) pt->context->tls_ops->fake_POLLIN_for_buffered) m |= pt->context->tls_ops->fake_POLLIN_for_buffered(pt); - if (!m && !n) { - lws_service_fd_tsi(context, NULL, tsi); + if (!m && !n) return 0; - } - faked_service: m = lws_service_flag_pending(context, tsi); diff --git a/lib/plat/optee/network.c b/lib/plat/optee/network.c index 34441701a..8e04a7d4f 100644 --- a/lib/plat/optee/network.c +++ b/lib/plat/optee/network.c @@ -141,10 +141,8 @@ _lws_plat_service_tsi(struct lws_context *context, int timeout_ms, int tsi) pt->context->tls_ops->fake_POLLIN_for_buffered) m = pt->context->tls_ops->fake_POLLIN_for_buffered(pt); - if (/*!pt->ws.rx_draining_ext_list && */!m && !n) { /* nothing to do */ - lws_service_fd_tsi(context, NULL, tsi); + if (/*!pt->ws.rx_draining_ext_list && */!m && !n) /* nothing to do */ return 0; - } faked_service: m = lws_service_flag_pending(context, tsi); diff --git a/lib/plat/windows/windows-service.c b/lib/plat/windows/windows-service.c index 4e4212454..2850a5d5a 100644 --- a/lib/plat/windows/windows-service.c +++ b/lib/plat/windows/windows-service.c @@ -204,10 +204,13 @@ _lws_plat_service_tsi(struct lws_context *context, int timeout_ms, int tsi) lws_service_fd_tsi(context, pfd, tsi); } } - } else if (ev == WSA_WAIT_TIMEOUT) { - lws_service_fd(context, NULL); - } else if (ev == WSA_WAIT_FAILED) + return 0; + } + + // if (ev == WSA_WAIT_TIMEOUT) { } + // if (ev == WSA_WAIT_FAILED) + // return 0; return 0; }