mirror of
https://github.com/espressif/openthread.git
synced 2026-07-31 16:17:47 +00:00
[ip6] ensure slaac addresses are added back after reset (#2938)
This commit makes the following changes: 1. A child that is resynchronizing with its parent after reset always requests the network data to ensure that it has the latest version. 2. When autoconfiguring SLAAC addresses in response to a network data update always attempt to add the netif address buffer in case the netif structure was removed (e.g. due to reset).
This commit is contained in:
@@ -3491,6 +3491,8 @@ otError Mle::HandleChildUpdateResponse(const Message &aMessage, const Ip6::Messa
|
||||
mParent.SetState(Neighbor::kStateValid);
|
||||
SetStateChild(GetRloc16());
|
||||
|
||||
mRetrieveNewNetworkData = true;
|
||||
|
||||
// fall through
|
||||
|
||||
case OT_DEVICE_ROLE_CHILD:
|
||||
|
||||
@@ -115,6 +115,7 @@ void Slaac::UpdateAddresses(otInstance * aInstance,
|
||||
if (otIp6PrefixMatch(&config.mPrefix.mPrefix, &address->mAddress) >= config.mPrefix.mLength &&
|
||||
config.mPrefix.mLength == address->mPrefixLength)
|
||||
{
|
||||
otIp6AddUnicastAddress(aInstance, address);
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user