mirror of
https://github.com/me-no-dev/ESPAsyncWebServer.git
synced 2026-01-27 17:22:20 +01:00
Prevent an assertion failure when using WebSockets (#584)
Frequently when using Web Sockets you will get the assert failure:
assertion "new_rcv_ann_wnd <= 0xffff" failed: file "/Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/lwip/lwip/src/core/tcp.c", line 779, function: tcp_update_rcv_ann_wnd
This will happen particulary when you close the browser window. This change
prevents the issue from occuring.
This commit is contained in:
@@ -680,6 +680,7 @@ void AsyncWebSocketClient::_onData(void *pbuf, size_t plen){
|
||||
_client->close(true);
|
||||
} else {
|
||||
_status = WS_DISCONNECTING;
|
||||
_client->ackLater();
|
||||
_queueControl(new AsyncWebSocketControl(WS_DISCONNECT, data, datalen));
|
||||
}
|
||||
} else if(_pinfo.opcode == WS_PING){
|
||||
|
||||
Reference in New Issue
Block a user