mirror of
https://git.proxmox.com/git/mirror_frr
synced 2026-01-25 23:48:15 +00:00
zebra: Re-add tracking of redistribution events
Somewhere along the way we lost the tracking of redistribution events. Put them back in. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
62a9c814e1
commit
34fa087036
@ -521,6 +521,7 @@ int zsend_redistribute_route(int cmd, struct zserv *client, struct prefix *p,
|
||||
struct zapi_nexthop *api_nh;
|
||||
struct nexthop *nexthop;
|
||||
int count = 0;
|
||||
afi_t afi;
|
||||
|
||||
memset(&api, 0, sizeof(api));
|
||||
api.vrf_id = re->vrf_id;
|
||||
@ -528,6 +529,24 @@ int zsend_redistribute_route(int cmd, struct zserv *client, struct prefix *p,
|
||||
api.instance = re->instance;
|
||||
api.flags = re->flags;
|
||||
|
||||
afi = family2afi(p->family);
|
||||
switch (afi) {
|
||||
case AFI_IP:
|
||||
if (cmd == ZEBRA_REDISTRIBUTE_ROUTE_ADD)
|
||||
client->redist_v4_add_cnt++;
|
||||
else
|
||||
client->redist_v4_del_cnt++;
|
||||
break;
|
||||
case AFI_IP6:
|
||||
if (cmd == ZEBRA_REDISTRIBUTE_ROUTE_ADD)
|
||||
client->redist_v6_add_cnt++;
|
||||
else
|
||||
client->redist_v6_del_cnt++;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
/* Prefix. */
|
||||
api.prefix = *p;
|
||||
if (src_p) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user