]> git.puffer.fish Git - mirror/frr.git/commitdiff
ospfd: fix crash on "ospf send-extra-data zebra" 10407/head
authorIgor Ryzhov <iryzhov@nfware.com>
Sun, 23 Jan 2022 13:10:55 +0000 (16:10 +0300)
committerIgor Ryzhov <iryzhov@nfware.com>
Sun, 23 Jan 2022 13:10:55 +0000 (16:10 +0300)
`ospf->new_table` is NULL if the OSPF instance has no routes.

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

index 3d0804b0188ebf30b930279f1917f5869a269b08..9940ce1c6979e5499e14d0889d140759913dfb3a 100644 (file)
@@ -2223,6 +2223,9 @@ static void ospf_table_reinstall_routes(struct ospf *ospf,
 {
        struct route_node *rn;
 
+       if (!rt)
+               return;
+
        for (rn = route_top(rt); rn; rn = route_next(rn)) {
                struct ospf_route *or;