From a4c840e120238ef8415d2dc53bca9e206ffca8b0 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Fri, 4 Jul 1997 04:31:33 +0000 Subject: Base PLEN on the value of LONG_BIT instead of assuming based on MAX size of long and int. --- usr.bin/netstat/netstat.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'usr.bin/netstat') diff --git a/usr.bin/netstat/netstat.h b/usr.bin/netstat/netstat.h index 2e61c427f12..83220dac7c2 100644 --- a/usr.bin/netstat/netstat.h +++ b/usr.bin/netstat/netstat.h @@ -1,4 +1,4 @@ -/* $OpenBSD: netstat.h,v 1.8 1997/06/29 21:46:04 millert Exp $ */ +/* $OpenBSD: netstat.h,v 1.9 1997/07/04 04:31:32 millert Exp $ */ /* $NetBSD: netstat.h,v 1.6 1996/05/07 02:55:05 thorpej Exp $ */ /* @@ -38,12 +38,8 @@ #include -/* What is the max length of a pointer printed with %p? */ -#if (UINT_MAX == ULONG_MAX) -#define PLEN 10 -#else -#define PLEN 18 -#endif +/* What is the max length of a pointer printed with %p (including 0x)? */ +#define PLEN (LONG_BIT / 4 + 2) int Aflag; /* show addresses of protocol control block */ int aflag; /* show all sockets (including servers) */ -- cgit v1.2.3