mirror of
https://github.com/espressif/openthread.git
synced 2026-09-01 23:09:53 +00:00
[mle] reduce log error spam when Mle::IsDisabled() (#12763)
This commit updates `Mle::HandleUdpReceive()` to avoid logging an error when an MLE message is received while MLE is disabled. When `IsDisabled()` is true, the `VerifyOrExit` macro now exits the method without setting `error` to `kErrorInvalidState`. This ensures that the `LogProcessError()` call at the `exit` label does not emit an error log. This reduces log spam during testing/debugging.
This commit is contained in:
@@ -1604,7 +1604,7 @@ void Mle::HandleUdpReceive(Message &aMessage, const Ip6::MessageInfo &aMessageIn
|
||||
ExitNow();
|
||||
}
|
||||
|
||||
VerifyOrExit(!IsDisabled(), error = kErrorInvalidState);
|
||||
VerifyOrExit(!IsDisabled());
|
||||
VerifyOrExit(securitySuite == k154Security, error = kErrorParse);
|
||||
|
||||
SuccessOrExit(error = aMessage.ReadAtAndAdvanceOffset(header));
|
||||
|
||||
Reference in New Issue
Block a user