mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-06 09:00:55 +00:00
bgpd: Fix memory use after free
We were immediately using memory after it was freed. Fix. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
3292693b2f
commit
122eebd85a
@ -207,9 +207,9 @@ static void bgp_info_free(struct bgp_info *binfo)
|
||||
{
|
||||
/* unlink reference to parent, if any. */
|
||||
if (binfo->extra && binfo->extra->parent) {
|
||||
bgp_info_unlock((struct bgp_info *)binfo->extra->parent);
|
||||
bgp_unlock_node((struct bgp_node *)((struct bgp_info *)binfo
|
||||
->extra->parent)->net);
|
||||
bgp_info_unlock((struct bgp_info *)binfo->extra->parent);
|
||||
binfo->extra->parent = NULL;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user