diff options
author | Donald Sharp <sharpd@nvidia.com> | 2020-10-22 00:55:09 +0200 |
---|---|---|
committer | Donald Sharp <sharpd@nvidia.com> | 2020-10-22 00:55:09 +0200 |
commit | 37b4b3cc340e8198c8a45700ef981b79084913af (patch) | |
tree | 3ea024bd677829a4455b5428bbcaea207cd41f46 /eigrpd/eigrp_dump.c | |
parent | Merge pull request #7353 from AnuradhaKaruppiah/mh-cleanup-fix-1 (diff) | |
download | frr-37b4b3cc340e8198c8a45700ef981b79084913af.tar.xz frr-37b4b3cc340e8198c8a45700ef981b79084913af.zip |
eigrpd: Replace inet_ntoa with %pI4
Search and destroy the inet_ntoa usage in eigrp
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'eigrpd/eigrp_dump.c')
-rw-r--r-- | eigrpd/eigrp_dump.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/eigrpd/eigrp_dump.c b/eigrpd/eigrp_dump.c index 97de73116..924c169da 100644 --- a/eigrpd/eigrp_dump.c +++ b/eigrpd/eigrp_dump.c @@ -122,8 +122,8 @@ void eigrp_ip_header_dump(struct ip *iph) zlog_debug("ip_ttl %u", iph->ip_ttl); zlog_debug("ip_p %u", iph->ip_p); zlog_debug("ip_sum 0x%x", (uint32_t)iph->ip_sum); - zlog_debug("ip_src %s", inet_ntoa(iph->ip_src)); - zlog_debug("ip_dst %s", inet_ntoa(iph->ip_dst)); + zlog_debug("ip_src %pI4", &iph->ip_src); + zlog_debug("ip_dst %pI4", &iph->ip_dst); } /* @@ -204,8 +204,7 @@ void show_ip_eigrp_neighbor_sub(struct vty *vty, struct eigrp_neighbor *nbr, int detail) { - vty_out(vty, "%-3u %-17s %-21s", 0, eigrp_neigh_ip_string(nbr), - IF_NAME(nbr->ei)); + vty_out(vty, "%-3u %-17pI4 %-21s", 0, &nbr->src, IF_NAME(nbr->ei)); if (nbr->t_holddown) vty_out(vty, "%-7lu", thread_timer_remain_second(nbr->t_holddown)); @@ -231,8 +230,8 @@ void show_ip_eigrp_neighbor_sub(struct vty *vty, struct eigrp_neighbor *nbr, */ void show_ip_eigrp_topology_header(struct vty *vty, struct eigrp *eigrp) { - vty_out(vty, "\nEIGRP Topology Table for AS(%d)/ID(%s)\n\n", eigrp->AS, - inet_ntoa(eigrp->router_id)); + vty_out(vty, "\nEIGRP Topology Table for AS(%d)/ID(%pI4)\n\n", + eigrp->AS, &eigrp->router_id); vty_out(vty, "Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply\n r - reply Status, s - sia Status\n\n"); } @@ -269,8 +268,8 @@ void show_ip_eigrp_nexthop_entry(struct vty *vty, struct eigrp *eigrp, vty_out(vty, "%-7s%s, %s\n", " ", "via Connected", IF_NAME(te->ei)); else { - vty_out(vty, "%-7s%s%s (%u/%u), %s\n", " ", "via ", - inet_ntoa(te->adv_router->src), te->distance, + vty_out(vty, "%-7s%s%pI4 (%u/%u), %s\n", " ", "via ", + &te->adv_router->src, te->distance, te->reported_distance, IF_NAME(te->ei)); } } |