aboutsummaryrefslogtreecommitdiff
path: root/sys/net/route.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/net/route.c')
-rw-r--r--sys/net/route.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/net/route.c b/sys/net/route.c
index 6c051e389d82..2f4ae40e83aa 100644
--- a/sys/net/route.c
+++ b/sys/net/route.c
@@ -151,6 +151,14 @@ void
rt_table_destroy(struct rib_head *rh)
{
+ RIB_WLOCK(rh);
+ rh->rib_dying = true;
+ RIB_WUNLOCK(rh);
+
+#ifdef FIB_ALGO
+ fib_destroy_rib(rh);
+#endif
+
tmproutes_destroy(rh);
rn_walktree(&rh->rmhead.head, rt_freeentry, &rh->rmhead.head);