[network-data] ensure DATA_RESUBMIT_DELAY between SRV_DATA.ntf (#4485)

This commit is contained in:
Rongli Sun
2020-02-24 13:13:01 -08:00
committed by Jonathan Hui
parent 4bf95c6c7b
commit b2024b8153
+1 -1
View File
@@ -977,7 +977,7 @@ otError NetworkData::SendServerDataNotification(uint16_t aRloc16)
Coap::Message * message = NULL;
Ip6::MessageInfo messageInfo;
VerifyOrExit(mLastAttempt.GetValue() == 0 || ((TimerMilli::GetNow() - mLastAttempt) < kDataResubmitDelay),
VerifyOrExit(mLastAttempt.GetValue() == 0 || ((TimerMilli::GetNow() - mLastAttempt) > kDataResubmitDelay),
error = OT_ERROR_ALREADY);
VerifyOrExit((message = Get<Coap::Coap>().NewMessage()) != NULL, error = OT_ERROR_NO_BUFS);