mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-06 14:29:47 +00:00
zebra: free neighbor state before exit to avoid memleaks
Signed-off-by: Christian Hopps <chopps@labn.net>
This commit is contained in:
parent
1004137bf3
commit
11c9ab3202
@ -272,8 +272,13 @@ void zebra_neigh_init(void)
|
||||
|
||||
void zebra_neigh_terminate(void)
|
||||
{
|
||||
struct zebra_neigh_ent *n, *next;
|
||||
|
||||
if (!zrouter.neigh_info)
|
||||
return;
|
||||
|
||||
RB_FOREACH_SAFE (n, zebra_neigh_rb_head, &zneigh_info->neigh_rb_tree,
|
||||
next)
|
||||
zebra_neigh_free(n);
|
||||
XFREE(MTYPE_ZNEIGH_INFO, zneigh_info);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user