[mle] allow REED to attach to a better partition (#2483)

This commit is contained in:
Jonathan Hui
2018-01-17 16:46:24 +00:00
committed by GitHub
parent a6a0f1c213
commit cc26bb7862
+1 -3
View File
@@ -1427,10 +1427,8 @@ void Mle::HandleParentRequestTimer(void)
// fall through
case kParentRequestChild:
mParentRequestState = kParentRequestChild;
if (mParentCandidate.GetState() == Neighbor::kStateParentResponse &&
(mRole != OT_DEVICE_ROLE_CHILD || mReceivedResponseFromParent) &&
(mRole != OT_DEVICE_ROLE_CHILD || mReceivedResponseFromParent || mParentRequestMode == kAttachBetter) &&
SendChildIdRequest() == OT_ERROR_NONE)
{
mParentRequestState = kChildIdRequest;