]> git.puffer.fish Git - matthieu/frr.git/commitdiff
ospfd: Fixing Summary origination after range configuration
authorrgirada <rgirada@vmware.com>
Mon, 20 Mar 2023 11:22:26 +0000 (11:22 +0000)
committerMergify <37929162+mergify[bot]@users.noreply.github.com>
Thu, 23 Mar 2023 23:57:49 +0000 (23:57 +0000)
Description:
After area range config, summary lsas are aggerated to configured
route but later it was being flushed instead of the actual summary
lsa. This was seen when prefix-id of the aggregated route is same
as one of the actual summary route.
Here, aggregated summary lsa need to be returned to set the flag
SUMMARY_APPROVE after originating aggregated summary lsa but its not.
Which is being cleaned up as part of unapproved summary cleanup.
Corrected this now.

Issue: #13028

Signed-off-by: Rajesh Girada <rgirada@vmware.com>
(cherry picked from commit c8c1a240ab9653d74b3af009f850e150909f784e)

ospfd/ospf_lsa.c

index 3e8b7b283d0df48e5c61e4b59f2677c611605bb3..dff04abc67bf04bdff22a6f7b04e7bca5ed79b25 100644 (file)
@@ -1281,7 +1281,7 @@ static struct ospf_lsa *ospf_handle_summarylsa_lsId_chg(struct ospf *ospf,
                                                        struct in_addr old_id)
 {
        struct ospf_lsa *lsa = NULL;
-       struct ospf_lsa *new = NULL;
+       struct ospf_lsa *summary_lsa = NULL;
        struct summary_lsa *sl = NULL;
        struct ospf_area *old_area = NULL;
        struct prefix_ipv4 old_prefix;
@@ -1318,19 +1318,19 @@ static struct ospf_lsa *ospf_handle_summarylsa_lsId_chg(struct ospf *ospf,
 
        if (type == OSPF_SUMMARY_LSA) {
                /*Refresh the LSA with new LSA*/
-               ospf_summary_lsa_refresh(ospf, lsa);
+               summary_lsa = ospf_summary_lsa_refresh(ospf, lsa);
 
-               new = ospf_summary_lsa_prepare_and_flood(
-                       &old_prefix, old_metric, old_area, old_id);
+               ospf_summary_lsa_prepare_and_flood(&old_prefix, old_metric,
+                                                  old_area, old_id);
        } else {
                /*Refresh the LSA with new LSA*/
-               ospf_summary_asbr_lsa_refresh(ospf, lsa);
+               summary_lsa = ospf_summary_asbr_lsa_refresh(ospf, lsa);
 
-               new = ospf_asbr_summary_lsa_prepare_and_flood(
-                       &old_prefix, old_metric, old_area, old_id);
+               ospf_asbr_summary_lsa_prepare_and_flood(&old_prefix, old_metric,
+                                                       old_area, old_id);
        }
 
-       return new;
+       return summary_lsa;
 }
 
 /* Originate Summary-LSA. */