]> git.puffer.fish Git - mirror/frr.git/commitdiff
pimd: Be more careful looking up mroute statistics
authorDonald Sharp <sharpd@cumulusnetworks.com>
Mon, 31 Oct 2016 20:33:38 +0000 (16:33 -0400)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Thu, 22 Dec 2016 01:26:13 +0000 (20:26 -0500)
When we get a request to look up the mroute statistics
from the kernel, ensure that the interface returned
is a valid usable interface.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
pimd/pim_zlookup.c

index cdaf04566da15602d1967825ff261c6287adb40b..53fd0ce071ce776c349d89401e2736eb6c378960 100644 (file)
@@ -456,6 +456,9 @@ pim_zlookup_sg_statistics (struct channel_oil *c_oil)
       zlog_debug ("Sending Request for New Channel Oil Information(%s)", pim_str_sg_dump (&more));
     }
 
+  if (!ifp)
+    return -1;
+
   stream_reset (s);
   zclient_create_header (s, ZEBRA_IPMR_ROUTE_STATS, VRF_DEFAULT);
   stream_put_in_addr (s, &c_oil->oil.mfcc_origin);