Formatting: use early continue pattern
This commit is contained in:
@@ -234,8 +234,9 @@ void UdpCommandDemuxer::processIncomingData()
|
|||||||
// Found matching device in temporary collection, invoke matching handlers
|
// Found matching device in temporary collection, invoke matching handlers
|
||||||
for (const auto& cmdHandler : tempIt->second)
|
for (const auto& cmdHandler : tempIt->second)
|
||||||
{
|
{
|
||||||
if (cmdHandler.cmd_set == cmd_set && cmdHandler.cmd_id == cmd_id)
|
if (cmdHandler.cmd_set != cmd_set || cmdHandler.cmd_id != cmd_id)
|
||||||
{
|
{ continue; }
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
cmdHandler.handler(receiveBuffer, bytesReceived, senderAddr);
|
cmdHandler.handler(receiveBuffer, bytesReceived, senderAddr);
|
||||||
@@ -248,7 +249,6 @@ void UdpCommandDemuxer::processIncomingData()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user