mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 00:18:53 +00:00
pimd: don't leak original_s_route on error
original_s_route is allocated on the heap and was not freed during the error case. Signed-off-by: Christian Franke <chris@opensourcerouting.org> Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
6465ad8861
commit
2447614b9c
@ -198,6 +198,10 @@ int pim_static_add(struct interface *iif, struct interface *oif, struct in_addr
|
||||
pim_static_route_free(s_route);
|
||||
}
|
||||
|
||||
if (original_s_route) {
|
||||
pim_static_route_free(original_s_route);
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user