Fix missing receive loop for mqttclient

This commit is contained in:
hsaturn
2021-04-11 21:21:48 +02:00
parent b023cd67a9
commit 28b0ac1611

View File

@@ -271,6 +271,17 @@ void MqttClient::loop()
// there is no need to send one PingReq per instance.
}
}
#ifndef TCP_ASYNC
while(client && client->available()>0)
{
message.incoming(client->read());
if (message.type())
{
processMessage(&message);
message.reset();
}
}
#endif
}
void MqttClient::onConnect(void *mqttclient_ptr, TcpClient*)