Skip to content
This repository was archived by the owner on Jan 20, 2025. It is now read-only.

Commit 5ea49e3

Browse files
matt123pme-no-dev
authored andcommitted
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.
1 parent 41cf489 commit 5ea49e3

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/AsyncWebSocket.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -680,6 +680,7 @@ void AsyncWebSocketClient::_onData(void *pbuf, size_t plen){
680680
_client->close(true);
681681
} else {
682682
_status = WS_DISCONNECTING;
683+
_client->ackLater();
683684
_queueControl(new AsyncWebSocketControl(WS_DISCONNECT, data, datalen));
684685
}
685686
} else if(_pinfo.opcode == WS_PING){

0 commit comments

Comments
 (0)