]> git.proxmox.com Git - mirror_frr.git/commitdiff
ospfd: correctly cleanup spf data
authorIgor Ryzhov <iryzhov@nfware.com>
Tue, 31 Aug 2021 10:41:40 +0000 (13:41 +0300)
committerIgor Ryzhov <iryzhov@nfware.com>
Tue, 31 Aug 2021 10:41:40 +0000 (13:41 +0300)
ospf_spf_cleanup frees the data so we need to reset the stale pointers.

Fixes #9523.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
ospfd/ospf_spf.c

index 6a51440266e0a501146a9e4817610ca66f60cfad..8b4d55984c8044d2b2a6873d8bd1d400643e1a91 100644 (file)
@@ -1781,6 +1781,9 @@ void ospf_spf_calculate_area(struct ospf *ospf, struct ospf_area *area,
                                    ospf->ti_lfa_protection_type);
 
        ospf_spf_cleanup(area->spf, area->spf_vertex_list);
+
+       area->spf = NULL;
+       area->spf_vertex_list = NULL;
 }
 
 void ospf_spf_calculate_areas(struct ospf *ospf, struct route_table *new_table,