]> git.puffer.fish Git - mirror/frr.git/commitdiff
pimd: allow pimd to handle nexthop_lookup zapi error
authorStephen Worley <sworley@cumulusnetworks.com>
Fri, 13 Dec 2019 01:14:51 +0000 (20:14 -0500)
committerStephen Worley <sworley@cumulusnetworks.com>
Wed, 8 Jan 2020 17:22:30 +0000 (12:22 -0500)
Allow pimd to stop the lookup if zebra tells pimd that the
lookup failed due to a zapi error. Otherwise, it will keep
waiting for a nexthop message that will never come.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
pimd/pim_zlookup.c

index 77526281d18c1c8a2a479c4fc766bb03d864faa2..13b6fdf22f172aae165eabd68cdcad826a77dec9 100644 (file)
@@ -180,6 +180,14 @@ static int zclient_read_nexthop(struct pim_instance *pim,
                        zclient_lookup_failed(zlookup);
                        return -1;
                }
+
+               if (command == ZEBRA_ERROR) {
+                       enum zebra_error_types error;
+
+                       zapi_error_decode(s, &error);
+                       /* Do nothing with it for now */
+                       return -1;
+               }
        }
 
        raddr.s_addr = stream_get_ipv4(s);