[panid-query-server] change SendConflict() to return void (#4941)

This commit is contained in:
Jonathan Hui
2020-05-11 12:44:54 -07:00
parent 30bf77808e
commit 71af8794bd
2 changed files with 10 additions and 7 deletions
+9 -6
View File
@@ -104,11 +104,11 @@ void PanIdQueryServer::HandleScanResult(Mac::ActiveScanResult *aScanResult)
}
else if (mChannelMask != 0)
{
IgnoreError(SendConflict());
SendConflict();
}
}
otError PanIdQueryServer::SendConflict(void)
void PanIdQueryServer::SendConflict(void)
{
otError error = OT_ERROR_NONE;
MeshCoP::ChannelMaskTlv channelMask;
@@ -135,12 +135,15 @@ otError PanIdQueryServer::SendConflict(void)
exit:
if (error != OT_ERROR_NONE && message != NULL)
if (error != OT_ERROR_NONE)
{
message->Free();
}
otLogWarnMeshCoP("Failed to send panid conflict: %s", otThreadErrorToString(error));
return error;
if (message != NULL)
{
message->Free();
}
}
}
void PanIdQueryServer::HandleTimer(Timer &aTimer)
+1 -1
View File
@@ -75,7 +75,7 @@ private:
static void HandleUdpReceive(void *aContext, otMessage *aMessage, const otMessageInfo *aMessageInfo);
otError SendConflict(void);
void SendConflict(void);
Ip6::Address mCommissioner;
uint32_t mChannelMask;