]> git.puffer.fish Git - matthieu/frr.git/commit
bgpd: static routes are leaked on shutdown
authorDonald Sharp <sharpd@nvidia.com>
Wed, 21 Dec 2022 17:11:56 +0000 (12:11 -0500)
committerDonald Sharp <sharpd@nvidia.com>
Wed, 21 Dec 2022 17:11:56 +0000 (12:11 -0500)
commitf9d6087c51fbeafc76f3c7f1b72681cbab7f3651
treed30264b969bbf0dc6993e0769574a2651c44bc43
parentaaa18e0e6fea51244da40cf325caa945bedaf8cb
bgpd: static routes are leaked on shutdown

Shutdown of bgp results in both the bgp_path_info,
bgp_dest and bgp_table's not being freed because
the bgp_path_info remains locked.

Effectively static routes are scheduled for deletion but bgp_process
skips the work because the work queue sees that the bgp router
is marked for deletion.  Effectively not doing any work and leaving
data on the floor.

Modify the code when attempting to put into the work queue to
notice and not do so but just unlock the path info.

This is effectively the same as what goes on for normal peering
as that it checks for shutdown and just calls bgp_path_info_free
too.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
bgpd/bgp_route.c