Skip to content

Commit 80857e3

Browse files
author
Denver Abrey
committed
Also set timeout on already existing connections
1 parent d1a6b32 commit 80857e3

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

libraries/ESP8266HTTPClient/src/ESP8266HTTPClient.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,9 @@ void HTTPClient::setAuthorization(const char * auth) {
259259
*/
260260
void HTTPClient::setTimeout(uint16_t timeout) {
261261
_tcpTimeout = timeout;
262+
if(connected()) {
263+
_tcp->setTimeout(timeout);
264+
}
262265
}
263266

264267
/**

0 commit comments

Comments
 (0)