1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-09-09 18:40:33 +03:00

Fix WiFiClient assignment operator

This commit is contained in:
Ivan Grokhotkov
2015-02-16 03:02:42 +03:00
parent b85262e634
commit ea90d3ce92
2 changed files with 3 additions and 0 deletions

View File

@@ -70,6 +70,8 @@ ICACHE_FLASH_ATTR WiFiClient::WiFiClient(const WiFiClient& other)
WiFiClient& ICACHE_FLASH_ATTR WiFiClient::operator=(const WiFiClient& other)
{
if (_client)
_client->unref();
_client = other._client;
if (_client)
_client->ref();