[meshcop] do not allow timestamp rollback on leader (#5249)

This commit is contained in:
Jonathan Hui
2020-07-17 08:50:09 -07:00
committed by GitHub
parent c394080617
commit 85af5f1963
+1
View File
@@ -169,6 +169,7 @@ otError DatasetManager::Save(const Dataset &aDataset)
}
else if (compare < 0)
{
VerifyOrExit(!Get<Mle::MleRouter>().IsLeader(), error = OT_ERROR_INVALID_STATE);
SendSet();
}