pimd: allow pimd to handle nexthop_lookup zapi error

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>
This commit is contained in:
Stephen Worley 2019-12-12 20:14:51 -05:00
parent 9ab0b2a37a
commit 7713e71a10

View 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);