]> git.proxmox.com Git - mirror_frr.git/blobdiff - zebra/zebra_router.c
zebra: Fix memory leaks and use after frees in nhg's on shutdown
[mirror_frr.git] / zebra / zebra_router.c
index f7ad30b41fb337b76694c277a5a08135816e42af..24e71b4a8b8266d31a676147a0e9e86eecddbd38 100644 (file)
@@ -246,6 +246,7 @@ void zebra_router_terminate(void)
        zebra_neigh_terminate();
 
        /* Free NHE in ID table only since it has unhashable entries as well */
+       hash_iterate(zrouter.nhgs_id, zebra_nhg_hash_free_zero_id, NULL);
        hash_clean(zrouter.nhgs_id, zebra_nhg_hash_free);
        hash_free(zrouter.nhgs_id);
        hash_clean(zrouter.nhgs, NULL);