Skip to content

Commit a2e7c7d

Browse files
d-a-vdevyte
authored andcommitted
(bool)WiFiClient needs to return ::connected() since ClientContext is not destroyed on ::stop() (esp8266#4422)
1 parent 1349baf commit a2e7c7d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libraries/ESP8266WiFi/src/WiFiClient.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -290,9 +290,9 @@ uint8_t WiFiClient::status()
290290
return _client->state();
291291
}
292292

293-
WiFiClient::operator bool()
293+
WiFiClient::operator bool()
294294
{
295-
return _client != 0;
295+
return connected();
296296
}
297297

298298
IPAddress WiFiClient::remoteIP()

0 commit comments

Comments
 (0)