summaryrefslogtreecommitdiff
path: root/babeld/babel_zebra.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2017-05-24 20:11:15 -0400
committerDonald Sharp <sharpd@cumulusnetworks.com>2017-05-24 20:14:53 -0400
commite9047736f79f18d2cd741b6af943be91e7839578 (patch)
tree64d517eb90803b34731cf43dca64f290967ea709 /babeld/babel_zebra.c
parent64682f5e69efa99708839ca25397c37c2ed8b674 (diff)
babeld: Fix redistribute events for v4/6 up from zebra
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'babeld/babel_zebra.c')
-rw-r--r--babeld/babel_zebra.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/babeld/babel_zebra.c b/babeld/babel_zebra.c
index e09c265347..f54f5b3469 100644
--- a/babeld/babel_zebra.c
+++ b/babeld/babel_zebra.c
@@ -102,7 +102,8 @@ babel_zebra_read_ipv6 (int command, struct zclient *zclient,
/* Type, flags, message. */
api.type = stream_getc (s);
- api.flags = stream_getc (s);
+ api.instance = stream_getw (s);
+ api.flags = stream_getl (s);
api.message = stream_getc (s);
/* IPv6 prefix. */
@@ -128,7 +129,7 @@ babel_zebra_read_ipv6 (int command, struct zclient *zclient,
else
api.metric = 0;
- if (command == ZEBRA_IPV6_ROUTE_ADD)
+ if (command == ZEBRA_REDISTRIBUTE_IPV6_ADD)
babel_ipv6_route_add(&api, &prefix, ifindex, &nexthop);
else
babel_ipv6_route_delete(&api, &prefix, ifindex);
@@ -154,7 +155,8 @@ babel_zebra_read_ipv4 (int command, struct zclient *zclient,
/* Type, flags, message. */
api.type = stream_getc (s);
- api.flags = stream_getc (s);
+ api.instance = stream_getw (s);
+ api.flags = stream_getl (s);
api.message = stream_getc (s);
/* IPv6 prefix. */
@@ -180,7 +182,7 @@ babel_zebra_read_ipv4 (int command, struct zclient *zclient,
else
api.metric = 0;
- if (command == ZEBRA_IPV4_ROUTE_ADD) {
+ if (command == ZEBRA_REDISTRIBUTE_IPV4_ADD) {
babel_ipv4_route_add(&api, &prefix, ifindex, &nexthop);
} else {
babel_ipv4_route_delete(&api, &prefix, ifindex);