mirror of
https://github.com/eclipse/paho.mqtt-sn.embedded-c.git
synced 2025-12-15 16:36:52 +01:00
@@ -178,14 +178,14 @@ void ClientRecvTask::run()
|
|||||||
|
|
||||||
client = clientList->getClient(&data.clientID);
|
client = clientList->getClient(&data.clientID);
|
||||||
|
|
||||||
if ( fwd )
|
if ( fwd != nullptr )
|
||||||
{
|
{
|
||||||
if ( client == nullptr )
|
if ( client == nullptr )
|
||||||
{
|
{
|
||||||
/* create a new client */
|
/* create a new client */
|
||||||
client = clientList->createClient(0, &data.clientID, clientType);
|
client = clientList->createClient(0, &data.clientID, clientType);
|
||||||
}
|
}
|
||||||
/* Add to af forwarded client list of forwarder. */
|
/* Add to a forwarded client list of forwarder. */
|
||||||
fwd->addClient(client, &nodeId);
|
fwd->addClient(client, &nodeId);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -143,6 +143,7 @@ void Forwarder::addClient(Client* client, WirelessNodeId* id)
|
|||||||
if ( p->_client == client )
|
if ( p->_client == client )
|
||||||
{
|
{
|
||||||
client->setForwarder(this);
|
client->setForwarder(this);
|
||||||
|
p->setWirelessNodeId(id);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
prev = p;
|
prev = p;
|
||||||
|
|||||||
Reference in New Issue
Block a user