]> git.puffer.fish Git - mirror/frr.git/commitdiff
spf6d: fix use after free (Coverity 1221459) 2390/head
authorpaco <paco@voltanet.io>
Fri, 8 Jun 2018 17:46:48 +0000 (19:46 +0200)
committerpaco <paco@voltanet.io>
Fri, 8 Jun 2018 17:46:48 +0000 (19:46 +0200)
Signed-off-by: F. Aragon <paco@voltanet.io>
ospf6d/ospf6_flood.c

index 6040c53dce191a9c03e5fd134afe640db738eaab..2059d8486829c099daf136c1b853df2d8e418fc0 100644 (file)
@@ -349,8 +349,9 @@ void ospf6_flood_interface(struct ospf6_neighbor *from, struct ospf6_lsa *lsa,
                                                ospf6_lsa_unlock(req);
                                                on->last_ls_req = NULL;
                                        }
-                                       ospf6_lsdb_remove(req,
-                                                         on->request_list);
+                                       if (req)
+                                               ospf6_lsdb_remove(req,
+                                                       on->request_list);
                                        ospf6_check_nbr_loading(on);
                                        /* fall through */
                                }