1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-13 13:01:55 +03:00

webhook/http1.1: prevent from losing a new client while waiting (#7492)

This commit is contained in:
david gauchard
2020-07-30 01:26:56 +02:00
committed by GitHub
parent d5187790bd
commit 1041a9d752

View File

@ -366,7 +366,7 @@ void ESP8266WebServerTemplate<ServerType>::handleClient() {
break;
case HC_WAIT_CLOSE:
// Wait for client to close the connection
if (!_server.available() && (millis() - _statusChange <= HTTP_MAX_CLOSE_WAIT)) {
if (!_server.hasClient() && (millis() - _statusChange <= HTTP_MAX_CLOSE_WAIT)) {
keepCurrentClient = true;
callYield = true;
if (_currentClient.available())