diff options
author | deraadt <deraadt@openbsd.org> | 2015-01-16 06:39:28 +0000 |
---|---|---|
committer | deraadt <deraadt@openbsd.org> | 2015-01-16 06:39:28 +0000 |
commit | b9fc9a728fce9c4289b7e9a992665e28d5629a54 (patch) | |
tree | 72b2433e418dfa1aef5fcf8305617b97979a25d8 /usr.sbin/traceroute | |
parent | improve checksum parsing slightly. now handles filenames with spaces. (diff) | |
download | wireguard-openbsd-b9fc9a728fce9c4289b7e9a992665e28d5629a54.tar.xz wireguard-openbsd-b9fc9a728fce9c4289b7e9a992665e28d5629a54.zip |
Replace <sys/param.h> with <limits.h> and other less dirty headers where
possible. Annotate <sys/param.h> lines with their current reasons. Switch
to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change
MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where
sensible to avoid pulling in the pollution. These are the files confirmed
through binary verification.
ok guenther, millert, doug (helped with the verification protocol)
Diffstat (limited to 'usr.sbin/traceroute')
-rw-r--r-- | usr.sbin/traceroute/traceroute.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/traceroute/traceroute.c b/usr.sbin/traceroute/traceroute.c index d6ae260c4ca..257cf69ff9d 100644 --- a/usr.sbin/traceroute/traceroute.c +++ b/usr.sbin/traceroute/traceroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: traceroute.c,v 1.134 2014/12/09 17:46:24 millert Exp $ */ +/* $OpenBSD: traceroute.c,v 1.135 2015/01/16 06:40:22 deraadt Exp $ */ /* $NetBSD: traceroute.c,v 1.10 1995/05/21 15:50:45 mycroft Exp $ */ /* @@ -233,7 +233,6 @@ * Tue Dec 20 03:50:13 PST 1988 */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/uio.h> @@ -265,6 +264,7 @@ #include <stdlib.h> #include <string.h> #include <unistd.h> +#include <limits.h> #define MAX_LSRR ((MAX_IPOPTLEN - 4) / 4) @@ -1703,7 +1703,7 @@ in_cksum(u_short *addr, int len) const char * inetname(struct sockaddr *sa) { - static char line[NI_MAXHOST], domain[MAXHOSTNAMELEN + 1]; + static char line[NI_MAXHOST], domain[HOST_NAME_MAX+1 + 1]; static int first = 1; char *cp; |