From c5af37fbc7e1a5380a28c0418e45493591972812 Mon Sep 17 00:00:00 2001 From: Abtin Keshavarzian Date: Tue, 22 Nov 2022 17:54:57 -0800 Subject: [PATCH] [router-table] fix router next hop change on `Release(aRouterId)` (#8433) --- src/core/thread/router_table.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/thread/router_table.cpp b/src/core/thread/router_table.cpp index a45efe945..163a8c44f 100644 --- a/src/core/thread/router_table.cpp +++ b/src/core/thread/router_table.cpp @@ -291,7 +291,7 @@ Error RouterTable::Release(uint8_t aRouterId) for (router = GetFirstEntry(); router != nullptr; router = GetNextEntry(router)) { - if (router->GetNextHop() == rloc16) + if (router->GetNextHop() == aRouterId) { router->SetNextHop(Mle::kInvalidRouterId); router->SetCost(0);