diff options
author | Martin Buck <mb-tmp-tvguho.pbz@gromit.dyndns.org> | 2022-01-17 13:54:02 +0100 |
---|---|---|
committer | Martin Buck <mb-tmp-tvguho.pbz@gromit.dyndns.org> | 2022-01-20 15:18:32 +0100 |
commit | b74e965142d80b7827cd6ac1291e1a3a73b9e617 (patch) | |
tree | 787e1037069696304ec8f9f46eaf21dd343cdc41 /ospf6d/ospf6_abr.c | |
parent | Merge pull request #10335 from ton31337/fix/reduce_nesting_show_neighbor_bgp (diff) | |
download | frr-b74e965142d80b7827cd6ac1291e1a3a73b9e617.tar.xz frr-b74e965142d80b7827cd6ac1291e1a3a73b9e617.zip |
ospf6d: Fix ECMP inter-area route nexthop update
Fixes #9720. When updating an ECMP inter-area route, we compute
a new route and check whether that already exists. If so, we keep the old
route and only update its nexthops. Previously, we merged the new route's
nexthops into the old one's, but this way, it's impossible to remove
nexthops from the old route, resulting in stale nexthops.
This commit fixes this by first removing all nexthops from the old route and
then copying all nexthops from the new route into it. If the new route has
fewer nexthops, the old one will have as well afterwards.
Signed-off-by: Martin Buck <mb-tmp-tvguho.pbz@gromit.dyndns.org>
Diffstat (limited to 'ospf6d/ospf6_abr.c')
-rw-r--r-- | ospf6d/ospf6_abr.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ospf6d/ospf6_abr.c b/ospf6d/ospf6_abr.c index 443759344..5af1139d9 100644 --- a/ospf6d/ospf6_abr.c +++ b/ospf6d/ospf6_abr.c @@ -1276,7 +1276,8 @@ void ospf6_abr_examin_summary(struct ospf6_lsa *lsa, struct ospf6_area *oa) continue; } - ospf6_route_merge_nexthops(old_route, route); + list_delete_all_node(old_route->nh_list); + ospf6_route_copy_nexthops(old_route, route); old_entry_updated = true; for (ALL_LIST_ELEMENTS_RO(old_route->paths, anode, |