diff options
author | paul <paul> | 2005-09-21 12:30:08 +0000 |
---|---|---|
committer | paul <paul> | 2005-09-21 12:30:08 +0000 |
commit | 319572cc52267bfd55cca5eaab405df4db27ddaf (patch) | |
tree | 576a148fe8515caf60bde98505a41845068c1d4d /zebra | |
parent | 5339cfdb7c3f6187452982173aa55ff525d1f6fe (diff) |
2005-09-21 Paul Jakma <paul.jakma@sun.com>
* zebra_rib.c: (static_uninstall_ipv{4,6}) Fix regression wrt
removal of static routes with multiple-hops introduced with
the workqueue conversion. We should free the relevant
nexthop and then get rib_process to run, otherwise we just
get same static route back again (with no way to unconfigure
it, because its already deleted from configuration).
Diffstat (limited to 'zebra')
-rw-r--r-- | zebra/ChangeLog | 9 | ||||
-rw-r--r-- | zebra/zebra_rib.c | 8 |
2 files changed, 15 insertions, 2 deletions
diff --git a/zebra/ChangeLog b/zebra/ChangeLog index 6225ce1a..9939d3e3 100644 --- a/zebra/ChangeLog +++ b/zebra/ChangeLog @@ -1,3 +1,12 @@ +2005-09-21 Paul Jakma <paul.jakma@sun.com> + + * zebra_rib.c: (static_uninstall_ipv{4,6}) Fix regression wrt + removal of static routes with multiple-hops introduced with + the workqueue conversion. We should free the relevant + nexthop and then get rib_process to run, otherwise we just + get same static route back again (with no way to unconfigure + it, because its already deleted from configuration). + 2005-09-12 Paul Jakma <paul.jakma@sun.com> * (general) RTM_CHANGE and implicit withdraw on RTM_NEWADDR diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c index 6d947c85..6cb686b7 100644 --- a/zebra/zebra_rib.c +++ b/zebra/zebra_rib.c @@ -1557,7 +1557,9 @@ static_uninstall_ipv4 (struct prefix *p, struct static_ipv4 *si) { if (CHECK_FLAG (nexthop->flags, NEXTHOP_FLAG_FIB)) rib_uninstall (rn, rib); - rib_queue_add (&zebrad, rn, rib); + nexthop_delete (rib, nexthop); + nexthop_free (nexthop); + rib_queue_add (&zebrad, rn, NULL); } /* Unlock node. */ route_unlock_node (rn); @@ -2106,7 +2108,9 @@ static_uninstall_ipv6 (struct prefix *p, struct static_ipv6 *si) { if (CHECK_FLAG (nexthop->flags, NEXTHOP_FLAG_FIB)) rib_uninstall (rn, rib); - rib_queue_add (&zebrad, rn, rib); + nexthop_delete (rib, nexthop); + nexthop_free (nexthop); + rib_queue_add (&zebrad, rn, NULL); } /* Unlock node. */ route_unlock_node (rn); |