aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/netstat/nhops.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/netstat/nhops.c')
-rw-r--r--usr.bin/netstat/nhops.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/usr.bin/netstat/nhops.c b/usr.bin/netstat/nhops.c
index f4c76f54a420..1a5d8eee74b1 100644
--- a/usr.bin/netstat/nhops.c
+++ b/usr.bin/netstat/nhops.c
@@ -64,16 +64,15 @@
#include "common.h"
/* column widths; each followed by one space */
+#define WID_IF_DEFAULT (Wflag ? IFNAMSIZ : 12) /* width of netif column */
#ifndef INET6
#define WID_DST_DEFAULT(af) 18 /* width of destination column */
#define WID_GW_DEFAULT(af) 18 /* width of gateway column */
-#define WID_IF_DEFAULT(af) (Wflag ? 10 : 8) /* width of netif column */
#else
#define WID_DST_DEFAULT(af) \
((af) == AF_INET6 ? (numeric_addr ? 33: 18) : 18)
#define WID_GW_DEFAULT(af) \
((af) == AF_INET6 ? (numeric_addr ? 29 : 18) : 18)
-#define WID_IF_DEFAULT(af) ((af) == AF_INET6 ? 8 : (Wflag ? 10 : 8))
#endif /*INET6*/
static int wid_dst;
static int wid_gw;
@@ -415,7 +414,7 @@ print_nhops_sysctl(int fibnum, int af)
wid_flags = 6;
wid_pksent = 8;
wid_mtu = 6;
- wid_if = WID_IF_DEFAULT(fam);
+ wid_if = WID_IF_DEFAULT;
xo_open_instance("rt-family");
pr_family(fam);
xo_open_list("nh-entry");