Generate the QoSm1Proxy Name from the Gateway Id.

Bugfix of AggregatePublish
Memory leak of ClientList

Signed-off-by: tomoaki <tomoaki@tomy-tech.com>
This commit is contained in:
tomoaki
2018-08-14 08:11:11 +09:00
parent 97cffe4573
commit 9de1dc3705
9 changed files with 32 additions and 46 deletions

View File

@@ -114,17 +114,17 @@ MQTTGWPacket* MQTTSNPublishHandler::handlePublish(Client* client, MQTTSNPacket*
MQTTGWPacket* publish = new MQTTGWPacket();
publish->setPUBLISH(&pub);
if ( !_gateway->getAdapterManager()->isAggregaterActive() )
if ( _gateway->getAdapterManager()->isAggregaterActive() && client->isAggregated() )
{
return publish;
}
else
{
Event* ev1 = new Event();
ev1->setBrokerSendEvent(client, publish);
_gateway->getBrokerSendQue()->post(ev1);
return nullptr;
}
else
{
return publish;
}
}
void MQTTSNPublishHandler::handlePuback(Client* client, MQTTSNPacket* packet)