Browse Source

ospf6d: Adding the initialization check in ospfv3_clean()

This is to avoid a crash triggered by process termination
when ospf6d daemon is running and 'router ospf6' config has not been done yet.

Signed-off-by: Vipin Kumar <vipin@cumulusnetworks.com>
Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com>
Vipin Kumar 4 years ago
parent
commit
7d39125ea4
1 changed files with 2 additions and 0 deletions
  1. 2 0
      ospf6d/ospf6d.c

+ 2 - 0
ospf6d/ospf6d.c

@@ -1854,6 +1854,8 @@ ospf6_init (void)
 void
 ospf6_clean (void)
 {
+  if (!ospf6)
+    return;
   if (ospf6->route_table)
     ospf6_route_remove_all (ospf6->route_table);
   if (ospf6->brouter_table)