summaryrefslogtreecommitdiffstats
path: root/ospf6d
diff options
context:
space:
mode:
authorRenato Westphal <renato@opensourcerouting.org>2021-08-18 23:40:07 +0200
committerRenato Westphal <renato@opensourcerouting.org>2021-08-24 05:24:41 +0200
commitdd551b9d1f78b5856d9b6fbc5abfa5e1d31d2775 (patch)
tree2c2c405e9b4f229e98a9399661e13a4beae06e20 /ospf6d
parentospf6d: fix flushing of all LSAs when NSSA is unconfigured (diff)
downloadfrr-dd551b9d1f78b5856d9b6fbc5abfa5e1d31d2775.tar.xz
frr-dd551b9d1f78b5856d9b6fbc5abfa5e1d31d2775.zip
ospf6d: flush external LSAs when NSSA is configured
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'ospf6d')
-rw-r--r--ospf6d/ospf6_asbr.c4
-rw-r--r--ospf6d/ospf6_nssa.c3
2 files changed, 5 insertions, 2 deletions
diff --git a/ospf6d/ospf6_asbr.c b/ospf6d/ospf6_asbr.c
index 2b11d89a3..92f9f0694 100644
--- a/ospf6d/ospf6_asbr.c
+++ b/ospf6d/ospf6_asbr.c
@@ -1307,9 +1307,9 @@ void ospf6_asbr_remove_externals_from_area(struct ospf6_area *oa)
struct ospf6 *ospf6 = oa->ospf6;
const struct route_node *iterend;
- /* skip if router is in other non-stub areas */
+ /* skip if router is in other non-stub/non-NSSA areas */
for (ALL_LIST_ELEMENTS(ospf6->area_list, node, nnode, area))
- if (!IS_AREA_STUB(area))
+ if (!IS_AREA_STUB(area) && !IS_AREA_NSSA(area))
return;
/* if router is only in a stub area then purge AS-External LSAs */
diff --git a/ospf6d/ospf6_nssa.c b/ospf6d/ospf6_nssa.c
index 7782dd877..cda92054a 100644
--- a/ospf6d/ospf6_nssa.c
+++ b/ospf6d/ospf6_nssa.c
@@ -1218,6 +1218,9 @@ static void ospf6_area_nssa_update(struct ospf6_area *area)
if (IS_AREA_NSSA(area)) {
OSPF6_ROUTER_LSA_SCHEDULE(area);
+ /* Flush external LSAs. */
+ ospf6_asbr_remove_externals_from_area(area);
+
/* Check if router is ABR */
if (ospf6_check_and_set_router_abr(area->ospf6)) {
if (IS_OSPF6_DEBUG_NSSA)