summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormaxim <maxim@FreeBSD.org>2016-03-18 15:06:50 +0000
committermaxim <maxim@FreeBSD.org>2016-03-18 15:06:50 +0000
commit2384b1d7357ce4e234dd75b17c1052779b4eae86 (patch)
tree3725f3a079a38e5697748823fbb8b5c9b3e83d7b
parent825daa4d0e6531316650e698d0ffcf249c4e794a (diff)
downloadFreeBSD-src-2384b1d7357ce4e234dd75b17c1052779b4eae86.zip
FreeBSD-src-2384b1d7357ce4e234dd75b17c1052779b4eae86.tar.gz
o No need to resolve a mask that we get with ICMP_MASKREPLY,
pass it directly to inet_ntoa(3).
-rw-r--r--sbin/ping/ping.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sbin/ping/ping.c b/sbin/ping/ping.c
index a5f8602..5b276fc 100644
--- a/sbin/ping/ping.c
+++ b/sbin/ping/ping.c
@@ -1201,7 +1201,7 @@ pr_pack(char *buf, int cc, struct sockaddr_in *from, struct timeval *tv)
if (options & F_MASK) {
/* Just prentend this cast isn't ugly */
(void)printf(" mask=%s",
- pr_addr(*(struct in_addr *)&(icp->icmp_mask)));
+ inet_ntoa(*(struct in_addr *)&(icp->icmp_mask)));
}
if (options & F_TIME) {
(void)printf(" tso=%s", pr_ntime(icp->icmp_otime));
OpenPOWER on IntegriCloud