]> git.proxmox.com Git - mirror_frr.git/commitdiff
pimd: Fix crash in channel_oil_add_oif
authorDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 24 Aug 2016 15:23:41 +0000 (11:23 -0400)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Thu, 22 Dec 2016 01:26:07 +0000 (20:26 -0500)
Remove assert, warn user that there is a
problem and move on.

Ticket: CM-12614
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
pimd/pim_oil.c

index d3895ea286db77638c50ab6b88bf2cd46b594615..e09dc3f089568bcd1f8883e95281bc17f9896fd4 100644 (file)
@@ -212,7 +212,15 @@ int pim_channel_add_oif(struct channel_oil *channel_oil,
   struct pim_interface *pim_ifp;
   int old_ttl;
 
-  zassert(channel_oil);
+  /*
+   * If we've gotten here we've gone bad, but let's
+   * not take down pim
+   */
+  if (!channel_oil)
+    {
+      zlog_warn ("Attempt to Add OIF for non-existent channel oil");
+      return -1;
+    }
 
   pim_ifp = oif->info;