summaryrefslogtreecommitdiff
path: root/zebra/zserv.c
diff options
context:
space:
mode:
Diffstat (limited to 'zebra/zserv.c')
-rw-r--r--zebra/zserv.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/zebra/zserv.c b/zebra/zserv.c
index 3402bf1dfb..e617ae28a2 100644
--- a/zebra/zserv.c
+++ b/zebra/zserv.c
@@ -641,7 +641,7 @@ zsend_redistribute_route (int cmd, struct zserv *client, struct prefix *p,
for (nexthop = rib->nexthop; nexthop; nexthop = nexthop->next)
{
/* We don't send any nexthops when there's a multipath */
- if (rib->nexthop_active_num > 1)
+ if (rib->nexthop_active_num > 1 && client->proto != ZEBRA_ROUTE_LDP)
{
SET_FLAG (zapi_flags, ZAPI_MESSAGE_NEXTHOP);
SET_FLAG (zapi_flags, ZAPI_MESSAGE_IFINDEX);
@@ -713,7 +713,9 @@ zsend_redistribute_route (int cmd, struct zserv *client, struct prefix *p,
stream_putc (s, 1);
stream_putl (s, nexthop->ifindex);
- break;
+ /* ldpd needs all nexthops */
+ if (client->proto != ZEBRA_ROUTE_LDP)
+ break;
}
}