Fix Route TLV handling during reattach. (#1168)

- When operating as a Router and attempting to reattach as a child,
  reset to the Detached state before calling ProcessRouteTlv.  Otherwise,
  ProcessRouteTlv will trigger another reattach since the previous
  Router ID cannot be found in the Router Mask.
This commit is contained in:
Jonathan Hui
2017-01-17 19:23:03 -08:00
committed by GitHub
parent 3f243ed540
commit 9113ffa3e9
+1
View File
@@ -2553,6 +2553,7 @@ ThreadError Mle::HandleChildIdResponse(const Message &aMessage, const Ip6::Messa
// Parent Attach Success
mParentRequestTimer.Stop();
mReattachState = kReattachStop;
SetStateDetached();
SetLeaderData(leaderData.GetPartitionId(), leaderData.GetWeighting(), leaderData.GetLeaderRouterId());