mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-06 07:37:54 +00:00
ripd: Convert to using %pFX
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
e0259674e3
commit
f42238f895
@ -603,8 +603,7 @@ int rip_interface_address_add(ZAPI_CALLBACK_ARGS)
|
||||
|
||||
if (p->family == AF_INET) {
|
||||
if (IS_RIP_DEBUG_ZEBRA)
|
||||
zlog_debug("connected address %s/%d is added",
|
||||
inet_ntoa(p->u.prefix4), p->prefixlen);
|
||||
zlog_debug("connected address %pFX is added", p);
|
||||
|
||||
rip_enable_apply(ifc->ifp);
|
||||
/* Check if this prefix needs to be redistributed */
|
||||
@ -653,9 +652,8 @@ int rip_interface_address_delete(ZAPI_CALLBACK_ARGS)
|
||||
p = ifc->address;
|
||||
if (p->family == AF_INET) {
|
||||
if (IS_RIP_DEBUG_ZEBRA)
|
||||
zlog_debug("connected address %s/%d is deleted",
|
||||
inet_ntoa(p->u.prefix4),
|
||||
p->prefixlen);
|
||||
zlog_debug("connected address %pFX is deleted",
|
||||
p);
|
||||
|
||||
hook_call(rip_ifaddr_del, ifc);
|
||||
|
||||
|
39
ripd/ripd.c
39
ripd/ripd.c
@ -337,8 +337,7 @@ static int rip_filter(int rip_distribute, struct prefix_ipv4 *p,
|
||||
(struct prefix *)p)
|
||||
== FILTER_DENY) {
|
||||
if (IS_RIP_DEBUG_PACKET)
|
||||
zlog_debug("%s/%d filtered by distribute %s",
|
||||
inet_ntoa(p->prefix), p->prefixlen,
|
||||
zlog_debug("%pFX filtered by distribute %s", p,
|
||||
inout);
|
||||
return -1;
|
||||
}
|
||||
@ -348,8 +347,7 @@ static int rip_filter(int rip_distribute, struct prefix_ipv4 *p,
|
||||
(struct prefix *)p)
|
||||
== PREFIX_DENY) {
|
||||
if (IS_RIP_DEBUG_PACKET)
|
||||
zlog_debug("%s/%d filtered by prefix-list %s",
|
||||
inet_ntoa(p->prefix), p->prefixlen,
|
||||
zlog_debug("%pFX filtered by prefix-list %s", p,
|
||||
inout);
|
||||
return -1;
|
||||
}
|
||||
@ -367,9 +365,8 @@ static int rip_filter(int rip_distribute, struct prefix_ipv4 *p,
|
||||
== FILTER_DENY) {
|
||||
if (IS_RIP_DEBUG_PACKET)
|
||||
zlog_debug(
|
||||
"%s/%d filtered by distribute %s",
|
||||
inet_ntoa(p->prefix),
|
||||
p->prefixlen, inout);
|
||||
"%pFX filtered by distribute %s",
|
||||
p, inout);
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
@ -383,9 +380,8 @@ static int rip_filter(int rip_distribute, struct prefix_ipv4 *p,
|
||||
== PREFIX_DENY) {
|
||||
if (IS_RIP_DEBUG_PACKET)
|
||||
zlog_debug(
|
||||
"%s/%d filtered by prefix-list %s",
|
||||
inet_ntoa(p->prefix),
|
||||
p->prefixlen, inout);
|
||||
"%pFX filtered by prefix-list %s",
|
||||
p, inout);
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
@ -1603,8 +1599,7 @@ void rip_redistribute_add(struct rip *rip, int type, int sub_type,
|
||||
(void)rip_ecmp_add(rip, &newinfo);
|
||||
|
||||
if (IS_RIP_DEBUG_EVENT) {
|
||||
zlog_debug("Redistribute new prefix %s/%d",
|
||||
inet_ntoa(p->prefix), p->prefixlen);
|
||||
zlog_debug("Redistribute new prefix %pFX", p);
|
||||
}
|
||||
|
||||
rip_event(rip, RIP_TRIGGERED_UPDATE, 0);
|
||||
@ -1641,9 +1636,8 @@ void rip_redistribute_delete(struct rip *rip, int type, int sub_type,
|
||||
|
||||
if (IS_RIP_DEBUG_EVENT)
|
||||
zlog_debug(
|
||||
"Poison %s/%d on the interface %s with an infinity metric [delete]",
|
||||
inet_ntoa(p->prefix),
|
||||
p->prefixlen,
|
||||
"Poison %pFX on the interface %s with an infinity metric [delete]",
|
||||
p,
|
||||
ifindex2ifname(
|
||||
ifindex,
|
||||
rip->vrf->vrf_id));
|
||||
@ -2266,9 +2260,8 @@ void rip_output_process(struct connected *ifc, struct sockaddr_in *to,
|
||||
if (ret == RMAP_DENYMATCH) {
|
||||
if (IS_RIP_DEBUG_PACKET)
|
||||
zlog_debug(
|
||||
"RIP %s/%d is filtered by route-map out",
|
||||
inet_ntoa(p->prefix),
|
||||
p->prefixlen);
|
||||
"RIP %pFX is filtered by route-map out",
|
||||
p);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
@ -2283,9 +2276,8 @@ void rip_output_process(struct connected *ifc, struct sockaddr_in *to,
|
||||
if (ret == RMAP_DENYMATCH) {
|
||||
if (IS_RIP_DEBUG_PACKET)
|
||||
zlog_debug(
|
||||
"%s/%d is filtered by route-map",
|
||||
inet_ntoa(p->prefix),
|
||||
p->prefixlen);
|
||||
"%pFX is filtered by route-map",
|
||||
p);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
@ -2674,9 +2666,8 @@ void rip_redistribute_withdraw(struct rip *rip, int type)
|
||||
(struct prefix_ipv4 *)&rp->p;
|
||||
|
||||
zlog_debug(
|
||||
"Poisone %s/%d on the interface %s with an infinity metric [withdraw]",
|
||||
inet_ntoa(p->prefix),
|
||||
p->prefixlen,
|
||||
"Poisone %pFX on the interface %s with an infinity metric [withdraw]",
|
||||
p,
|
||||
ifindex2ifname(
|
||||
rinfo->nh.ifindex,
|
||||
rip->vrf->vrf_id));
|
||||
|
Loading…
Reference in New Issue
Block a user