summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@opensourcerouting.org>2021-10-04 12:21:45 +0200
committerDavid Lamparter <equinox@opensourcerouting.org>2022-03-27 14:57:22 +0200
commiteb3c9d97747bd0346a5ea951960c994dc2871ab3 (patch)
tree37c26069b60ce9c7a3abd0a560d1f97e9eecaeea /lib
parentzebra: `show ip nht mrib` (diff)
downloadfrr-eb3c9d97747bd0346a5ea951960c994dc2871ab3.tar.xz
frr-eb3c9d97747bd0346a5ea951960c994dc2871ab3.zip
*: add SAFI argument to zclient_send_rnh
Just pushing that SAFI_UNICAST up 1 level to the caller. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'lib')
-rw-r--r--lib/zclient.c8
-rw-r--r--lib/zclient.h3
2 files changed, 6 insertions, 5 deletions
diff --git a/lib/zclient.c b/lib/zclient.c
index f6c5a8af0..0c3421415 100644
--- a/lib/zclient.c
+++ b/lib/zclient.c
@@ -768,9 +768,9 @@ static void zclient_connect(struct thread *t)
}
enum zclient_send_status zclient_send_rnh(struct zclient *zclient, int command,
- const struct prefix *p,
- bool connected,
- bool resolve_via_def, vrf_id_t vrf_id)
+ const struct prefix *p, safi_t safi,
+ bool connected, bool resolve_via_def,
+ vrf_id_t vrf_id)
{
struct stream *s;
@@ -779,7 +779,7 @@ enum zclient_send_status zclient_send_rnh(struct zclient *zclient, int command,
zclient_create_header(s, command, vrf_id);
stream_putc(s, (connected) ? 1 : 0);
stream_putc(s, (resolve_via_def) ? 1 : 0);
- stream_putw(s, SAFI_UNICAST);
+ stream_putw(s, safi);
stream_putw(s, PREFIX_FAMILY(p));
stream_putc(s, p->prefixlen);
switch (PREFIX_FAMILY(p)) {
diff --git a/lib/zclient.h b/lib/zclient.h
index 092754f60..7e1283d83 100644
--- a/lib/zclient.h
+++ b/lib/zclient.h
@@ -1071,7 +1071,8 @@ extern enum zclient_send_status zclient_route_send(uint8_t, struct zclient *,
struct zapi_route *);
extern enum zclient_send_status
zclient_send_rnh(struct zclient *zclient, int command, const struct prefix *p,
- bool connected, bool resolve_via_default, vrf_id_t vrf_id);
+ safi_t safi, bool connected, bool resolve_via_default,
+ vrf_id_t vrf_id);
int zapi_nexthop_encode(struct stream *s, const struct zapi_nexthop *api_nh,
uint32_t api_flags, uint32_t api_message);
extern int zapi_route_encode(uint8_t, struct stream *, struct zapi_route *);