diff options
author | 2015-01-16 06:39:28 +0000 | |
---|---|---|
committer | 2015-01-16 06:39:28 +0000 | |
commit | b9fc9a728fce9c4289b7e9a992665e28d5629a54 (patch) | |
tree | 72b2433e418dfa1aef5fcf8305617b97979a25d8 /usr.sbin/tcpdump | |
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/tcpdump')
61 files changed, 80 insertions, 136 deletions
diff --git a/usr.sbin/tcpdump/addrtoname.c b/usr.sbin/tcpdump/addrtoname.c index 72f44e640d3..fb87a9fc9f3 100644 --- a/usr.sbin/tcpdump/addrtoname.c +++ b/usr.sbin/tcpdump/addrtoname.c @@ -1,4 +1,4 @@ -/* $OpenBSD: addrtoname.c,v 1.32 2014/10/08 04:58:50 deraadt Exp $ */ +/* $OpenBSD: addrtoname.c,v 1.33 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -24,7 +24,6 @@ * and address to string conversion routines */ -#include <sys/param.h> #include <sys/socket.h> #include <sys/time.h> #include <sys/types.h> @@ -55,6 +54,7 @@ struct rtentry; #include <string.h> #include <stdlib.h> #include <unistd.h> +#include <limits.h> #include "interface.h" #include "addrtoname.h" @@ -159,7 +159,7 @@ static u_int32_t netmask; char * getname(const u_char *ap) { - char host[MAXHOSTNAMELEN]; + char host[HOST_NAME_MAX+1]; u_int32_t addr; struct hnamemem *p; @@ -245,7 +245,7 @@ getname(const u_char *ap) char * getname6(const u_char *ap) { - char host[MAXHOSTNAMELEN]; + char host[HOST_NAME_MAX+1]; struct in6_addr addr; struct h6namemem *p; register char *cp; @@ -460,7 +460,7 @@ etheraddr_string(register const u_char *ep) return (tp->e_name); #ifdef HAVE_ETHER_NTOHOST if (!nflag) { - char buf[MAXHOSTNAMELEN + 1]; + char buf[HOST_NAME_MAX+1 + 1]; if (priv_ether_ntohost(buf, sizeof(buf), (struct ether_addr *)ep) > 0) { tp->e_name = savestr(buf); @@ -770,7 +770,7 @@ init_etherarray(void) register struct etherlist *el; register struct enamemem *tp; #ifdef HAVE_ETHER_NTOHOST - char name[MAXHOSTNAMELEN + 1]; + char name[HOST_NAME_MAX+1 + 1]; #else register struct pcap_etherent *ep; register FILE *fp; diff --git a/usr.sbin/tcpdump/print-802_11.c b/usr.sbin/tcpdump/print-802_11.c index e7a73af1b91..5f81f45ebca 100644 --- a/usr.sbin/tcpdump/print-802_11.c +++ b/usr.sbin/tcpdump/print-802_11.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-802_11.c,v 1.15 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-802_11.c,v 1.16 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2005 Reyk Floeter <reyk@openbsd.org> @@ -16,7 +16,6 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-arp.c b/usr.sbin/tcpdump/print-arp.c index 1f1c5123dce..4d4b97ffeea 100644 --- a/usr.sbin/tcpdump/print-arp.c +++ b/usr.sbin/tcpdump/print-arp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-arp.c,v 1.12 2009/10/27 23:59:55 deraadt Exp $ */ +/* $OpenBSD: print-arp.c,v 1.13 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-atalk.c b/usr.sbin/tcpdump/print-atalk.c index d8639b57ba4..513267660be 100644 --- a/usr.sbin/tcpdump/print-atalk.c +++ b/usr.sbin/tcpdump/print-atalk.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-atalk.c,v 1.27 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-atalk.c,v 1.28 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -23,7 +23,6 @@ * Format and print AppleTalk packets. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> @@ -43,6 +42,7 @@ struct rtentry; #include <stdio.h> #include <stdlib.h> #include <string.h> +#include <limits.h> #include "interface.h" #include "addrtoname.h" @@ -556,7 +556,7 @@ static void init_atalk(void) { struct hnamemem *tp; - char nambuf[MAXHOSTNAMELEN + 20]; + char nambuf[HOST_NAME_MAX+1 + 20]; char line[BUFSIZ]; int i1, i2, i3; @@ -587,7 +587,7 @@ ataddr_string(u_short atnet, u_char athost) { register struct hnamemem *tp, *tp2; register int i = (atnet << 8) | athost; - char nambuf[MAXHOSTNAMELEN + 20]; + char nambuf[HOST_NAME_MAX+1 + 20]; static int first = 1; if (first) { diff --git a/usr.sbin/tcpdump/print-atm.c b/usr.sbin/tcpdump/print-atm.c index 469cf7a2692..f9b1fdb94e8 100644 --- a/usr.sbin/tcpdump/print-atm.c +++ b/usr.sbin/tcpdump/print-atm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-atm.c,v 1.11 2014/11/20 04:11:33 jsg Exp $ */ +/* $OpenBSD: print-atm.c,v 1.12 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-bgp.c b/usr.sbin/tcpdump/print-bgp.c index 61b86c8ebc0..6d8ffa9ea6c 100644 --- a/usr.sbin/tcpdump/print-bgp.c +++ b/usr.sbin/tcpdump/print-bgp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-bgp.c,v 1.16 2014/01/12 11:26:48 deraadt Exp $ */ +/* $OpenBSD: print-bgp.c,v 1.17 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (C) 1999 WIDE Project. @@ -29,7 +29,6 @@ * SUCH DAMAGE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> @@ -40,6 +39,7 @@ #include <stdio.h> #include <string.h> #include <netdb.h> +#include <limits.h> #include "interface.h" #include "addrtoname.h" @@ -409,7 +409,7 @@ bgp_attr_print(const struct bgp_attr *attr, const u_char *dat, int len) int advance; int tlen, asn_bytes; const u_char *p; - char buf[MAXHOSTNAMELEN + 100]; + char buf[HOST_NAME_MAX+1 + 100]; p = dat; tlen = len; @@ -868,7 +868,7 @@ bgp_update_print(const u_char *dat, int length) #ifdef INET6 printf(" (Withdrawn routes: %d bytes)", len); #else - char buf[MAXHOSTNAMELEN + 100]; + char buf[HOST_NAME_MAX+1 + 100]; int wpfx; TCHECK2(p[2], len); @@ -949,7 +949,7 @@ bgp_update_print(const u_char *dat, int length) if (dat + length > p) { printf("(NLRI:"); /* ) */ while (dat + length > p) { - char buf[MAXHOSTNAMELEN + 100]; + char buf[HOST_NAME_MAX+1 + 100]; i = decode_prefix4(p, buf, sizeof(buf)); if (i == -1) { printf(" (illegal prefix length)"); diff --git a/usr.sbin/tcpdump/print-bootp.c b/usr.sbin/tcpdump/print-bootp.c index f7fdfd73ddc..a130b0e3b79 100644 --- a/usr.sbin/tcpdump/print-bootp.c +++ b/usr.sbin/tcpdump/print-bootp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-bootp.c,v 1.18 2013/10/27 18:49:25 guenther Exp $ */ +/* $OpenBSD: print-bootp.c,v 1.19 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1993, 1994, 1995, 1996, 1997 @@ -22,7 +22,6 @@ * * Format and print bootp packets. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-cdp.c b/usr.sbin/tcpdump/print-cdp.c index bfb20b0db6c..9af884697b0 100644 --- a/usr.sbin/tcpdump/print-cdp.c +++ b/usr.sbin/tcpdump/print-cdp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-cdp.c,v 1.4 2009/10/27 23:59:55 deraadt Exp $ */ +/* $OpenBSD: print-cdp.c,v 1.5 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1992, 1993, 1994, 1995, 1996, 1997 @@ -26,7 +26,6 @@ * http://www.cisco.com/univercd/cc/td/doc/product/lan/trsrb/frames.htm */ -#include <sys/param.h> #include <sys/time.h> #include <netinet/in.h> diff --git a/usr.sbin/tcpdump/print-decnet.c b/usr.sbin/tcpdump/print-decnet.c index 8615abff887..6e47c8d7508 100644 --- a/usr.sbin/tcpdump/print-decnet.c +++ b/usr.sbin/tcpdump/print-decnet.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-decnet.c,v 1.12 2009/10/27 23:59:55 deraadt Exp $ */ +/* $OpenBSD: print-decnet.c,v 1.13 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-dhcp6.c b/usr.sbin/tcpdump/print-dhcp6.c index 3546b6c9ac5..fd111244c17 100644 --- a/usr.sbin/tcpdump/print-dhcp6.c +++ b/usr.sbin/tcpdump/print-dhcp6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-dhcp6.c,v 1.7 2009/10/27 23:59:55 deraadt Exp $ */ +/* $OpenBSD: print-dhcp6.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (C) 1998 and 1999 WIDE Project. @@ -31,7 +31,6 @@ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-domain.c b/usr.sbin/tcpdump/print-domain.c index 8516e8f7fbe..211fc3a2b31 100644 --- a/usr.sbin/tcpdump/print-domain.c +++ b/usr.sbin/tcpdump/print-domain.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-domain.c,v 1.20 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-domain.c,v 1.21 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-dvmrp.c b/usr.sbin/tcpdump/print-dvmrp.c index 9ea358486c6..4d841278831 100644 --- a/usr.sbin/tcpdump/print-dvmrp.c +++ b/usr.sbin/tcpdump/print-dvmrp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-dvmrp.c,v 1.7 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-dvmrp.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1995, 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-enc.c b/usr.sbin/tcpdump/print-enc.c index 774857a0288..d2b64e26fe5 100644 --- a/usr.sbin/tcpdump/print-enc.c +++ b/usr.sbin/tcpdump/print-enc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-enc.c,v 1.12 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-enc.c,v 1.13 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1993, 1994, 1995, 1996 @@ -21,7 +21,7 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> +#include <sys/param.h> /* MSIZE */ #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-ether.c b/usr.sbin/tcpdump/print-ether.c index 3dea6e7f810..cffb77562b7 100644 --- a/usr.sbin/tcpdump/print-ether.c +++ b/usr.sbin/tcpdump/print-ether.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ether.c,v 1.28 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ether.c,v 1.29 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-etherip.c b/usr.sbin/tcpdump/print-etherip.c index 79327d637b7..640bdebac8e 100644 --- a/usr.sbin/tcpdump/print-etherip.c +++ b/usr.sbin/tcpdump/print-etherip.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-etherip.c,v 1.7 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-etherip.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2001 Jason L. Wright (jason@thought.net) @@ -30,7 +30,6 @@ * Format and print etherip packets */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-fddi.c b/usr.sbin/tcpdump/print-fddi.c index df80e6e1bbf..baa1597107a 100644 --- a/usr.sbin/tcpdump/print-fddi.c +++ b/usr.sbin/tcpdump/print-fddi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-fddi.c,v 1.15 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-fddi.c,v 1.16 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -22,7 +22,6 @@ */ #ifdef HAVE_FDDI -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-frag6.c b/usr.sbin/tcpdump/print-frag6.c index 074999fc8c2..be4c4a464d1 100644 --- a/usr.sbin/tcpdump/print-frag6.c +++ b/usr.sbin/tcpdump/print-frag6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-frag6.c,v 1.6 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-frag6.c,v 1.7 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1993, 1994 @@ -23,7 +23,6 @@ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-gre.c b/usr.sbin/tcpdump/print-gre.c index b89d5baaa3b..d88822bbefb 100644 --- a/usr.sbin/tcpdump/print-gre.c +++ b/usr.sbin/tcpdump/print-gre.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-gre.c,v 1.8 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-gre.c,v 1.9 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2002 Jason L. Wright (jason@thought.net) @@ -31,7 +31,6 @@ * RFC1701 (GRE), RFC1702 (GRE IPv4), and RFC2637 (Enhanced GRE) */ -#include <sys/param.h> #include <sys/time.h> #include <sys/uio.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-gtp.c b/usr.sbin/tcpdump/print-gtp.c index 55882d4c439..e977719b849 100644 --- a/usr.sbin/tcpdump/print-gtp.c +++ b/usr.sbin/tcpdump/print-gtp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-gtp.c,v 1.6 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-gtp.c,v 1.7 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2009, 2010 Joel Sing <jsing@openbsd.org> * @@ -40,7 +40,6 @@ * 3GPP TS 32.295 - Charging Data Record (CDR) transfer (GTPv1') */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/types.h> diff --git a/usr.sbin/tcpdump/print-iapp.c b/usr.sbin/tcpdump/print-iapp.c index 7bafd9d990f..614a917c4ce 100644 --- a/usr.sbin/tcpdump/print-iapp.c +++ b/usr.sbin/tcpdump/print-iapp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-iapp.c,v 1.4 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-iapp.c,v 1.5 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2005 Reyk Floeter <reyk@openbsd.org> @@ -16,7 +16,6 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-icmp.c b/usr.sbin/tcpdump/print-icmp.c index a693aea3c42..fe967c5088b 100644 --- a/usr.sbin/tcpdump/print-icmp.c +++ b/usr.sbin/tcpdump/print-icmp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-icmp.c,v 1.24 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-icmp.c,v 1.25 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1993, 1994, 1995, 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> @@ -40,6 +39,7 @@ struct rtentry; #include <stdio.h> #include <string.h> +#include <limits.h> #include "interface.h" #include "addrtoname.h" @@ -171,8 +171,8 @@ icmp_print(const u_char *bp, u_int length, const u_char *bp2) const struct ip *oip; const struct udphdr *ouh; u_int hlen, dport, mtu; - char buf[MAXHOSTNAMELEN+256]; - char buf2[MAXHOSTNAMELEN+256]; + char buf[HOST_NAME_MAX+1+256]; + char buf2[HOST_NAME_MAX+1+256]; dp = (struct icmp *)bp; ip = (struct ip *)bp2; diff --git a/usr.sbin/tcpdump/print-icmp6.c b/usr.sbin/tcpdump/print-icmp6.c index 7ac3e4a3aab..e80a4af6171 100644 --- a/usr.sbin/tcpdump/print-icmp6.c +++ b/usr.sbin/tcpdump/print-icmp6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-icmp6.c,v 1.14 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-icmp6.c,v 1.15 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1993, 1994 @@ -25,7 +25,6 @@ #include <ctype.h> -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-igrp.c b/usr.sbin/tcpdump/print-igrp.c index c463bfbcb8c..636e3dafcd8 100644 --- a/usr.sbin/tcpdump/print-igrp.c +++ b/usr.sbin/tcpdump/print-igrp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-igrp.c,v 1.6 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-igrp.c,v 1.7 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1996, 1997 @@ -23,7 +23,6 @@ * Initial contribution from Francis Dupont (francis.dupont@inria.fr) */ -#include <sys/param.h> #include <sys/types.h> /* concession to AIX */ #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ike.c b/usr.sbin/tcpdump/print-ike.c index 6490c06b952..94175355906 100644 --- a/usr.sbin/tcpdump/print-ike.c +++ b/usr.sbin/tcpdump/print-ike.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ike.c,v 1.36 2012/01/28 13:47:55 sthen Exp $ */ +/* $OpenBSD: print-ike.c,v 1.37 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999 @@ -27,7 +27,6 @@ * in co-operation with SSH Communications Security, Espoo, Finland */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ip.c b/usr.sbin/tcpdump/print-ip.c index 604f45aa652..d6940d7d1a2 100644 --- a/usr.sbin/tcpdump/print-ip.c +++ b/usr.sbin/tcpdump/print-ip.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ip.c,v 1.42 2014/12/09 17:03:19 mikeb Exp $ */ +/* $OpenBSD: print-ip.c,v 1.43 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ip6.c b/usr.sbin/tcpdump/print-ip6.c index f9c851a2c23..269c522cdc5 100644 --- a/usr.sbin/tcpdump/print-ip6.c +++ b/usr.sbin/tcpdump/print-ip6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ip6.c,v 1.20 2014/12/09 17:03:19 mikeb Exp $ */ +/* $OpenBSD: print-ip6.c,v 1.21 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994 @@ -23,7 +23,6 @@ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ip6opts.c b/usr.sbin/tcpdump/print-ip6opts.c index cdee34df886..9e7acf829a1 100644 --- a/usr.sbin/tcpdump/print-ip6opts.c +++ b/usr.sbin/tcpdump/print-ip6opts.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ip6opts.c,v 1.3 2006/12/09 01:12:28 itojun Exp $ */ +/* $OpenBSD: print-ip6opts.c,v 1.4 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (C) 1998 WIDE Project. @@ -30,7 +30,6 @@ */ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ipsec.c b/usr.sbin/tcpdump/print-ipsec.c index 51d2470638a..c04cb2da75d 100644 --- a/usr.sbin/tcpdump/print-ipsec.c +++ b/usr.sbin/tcpdump/print-ipsec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ipsec.c,v 1.19 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ipsec.c,v 1.20 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999 @@ -26,7 +26,6 @@ * in co-operation with SSH Communications Security, Espoo, Finland */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ipx.c b/usr.sbin/tcpdump/print-ipx.c index 6728c1ac2ed..b72f5367cad 100644 --- a/usr.sbin/tcpdump/print-ipx.c +++ b/usr.sbin/tcpdump/print-ipx.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ipx.c,v 1.13 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ipx.c,v 1.14 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1994, 1995, 1996 @@ -24,7 +24,6 @@ * Contributed by Brad Parker (brad@fcr.com). */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-krb.c b/usr.sbin/tcpdump/print-krb.c index 5f777834921..7a27cba9702 100644 --- a/usr.sbin/tcpdump/print-krb.c +++ b/usr.sbin/tcpdump/print-krb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-krb.c,v 1.9 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-krb.c,v 1.10 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1995, 1996, 1997 @@ -23,7 +23,6 @@ * Initial contribution from John Hawkinson (jhawk@mit.edu). */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-l2tp.c b/usr.sbin/tcpdump/print-l2tp.c index f8808442145..857bac9ab25 100644 --- a/usr.sbin/tcpdump/print-l2tp.c +++ b/usr.sbin/tcpdump/print-l2tp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-l2tp.c,v 1.7 2011/09/18 14:04:36 naddy Exp $ */ +/* $OpenBSD: print-l2tp.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1991, 1993, 1994, 1995, 1996, 1997 @@ -24,7 +24,6 @@ */ #include <sys/types.h> -#include <sys/param.h> #include <stdio.h> #include <strings.h> diff --git a/usr.sbin/tcpdump/print-llc.c b/usr.sbin/tcpdump/print-llc.c index 2f78c6809db..28eda54c6e7 100644 --- a/usr.sbin/tcpdump/print-llc.c +++ b/usr.sbin/tcpdump/print-llc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-llc.c,v 1.18 2009/10/27 23:59:55 deraadt Exp $ */ +/* $OpenBSD: print-llc.c,v 1.19 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1992, 1993, 1994, 1995, 1996, 1997 @@ -24,7 +24,6 @@ * with an awful lot of hacking by Jeffrey Mogul, DECWRL */ -#include <sys/param.h> #include <sys/time.h> #include <netinet/in.h> diff --git a/usr.sbin/tcpdump/print-lldp.c b/usr.sbin/tcpdump/print-lldp.c index 18e6c8e28df..98da2cbaad5 100644 --- a/usr.sbin/tcpdump/print-lldp.c +++ b/usr.sbin/tcpdump/print-lldp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-lldp.c,v 1.7 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-lldp.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2006 Reyk Floeter <reyk@openbsd.org> @@ -16,7 +16,6 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-lwres.c b/usr.sbin/tcpdump/print-lwres.c index b6113d3c688..5f91bcc8396 100644 --- a/usr.sbin/tcpdump/print-lwres.c +++ b/usr.sbin/tcpdump/print-lwres.c @@ -31,7 +31,6 @@ #include "config.h" #endif -#include <sys/param.h> #include <sys/time.h> #include <netinet/in.h> diff --git a/usr.sbin/tcpdump/print-mobile.c b/usr.sbin/tcpdump/print-mobile.c index cbfbaf99701..867b737f324 100644 --- a/usr.sbin/tcpdump/print-mobile.c +++ b/usr.sbin/tcpdump/print-mobile.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-mobile.c,v 1.4 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-mobile.c,v 1.5 2015/01/16 06:40:21 deraadt Exp $ */ /* $NetBSD: print-mobile.c,v 1.3 1999/07/26 06:11:57 itojun Exp $ */ /* @@ -30,7 +30,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/uio.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-netbios.c b/usr.sbin/tcpdump/print-netbios.c index 1c1f8d8b338..730db213e54 100644 --- a/usr.sbin/tcpdump/print-netbios.c +++ b/usr.sbin/tcpdump/print-netbios.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-netbios.c,v 1.9 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-netbios.c,v 1.10 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1994, 1995, 1996 @@ -24,7 +24,6 @@ * Contributed by Brad Parker (brad@fcr.com). */ -#include <sys/param.h> #include <sys/socket.h> #include <netinet/in.h> diff --git a/usr.sbin/tcpdump/print-nfs.c b/usr.sbin/tcpdump/print-nfs.c index 2edef633d33..daf3a0f86f3 100644 --- a/usr.sbin/tcpdump/print-nfs.c +++ b/usr.sbin/tcpdump/print-nfs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-nfs.c,v 1.18 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-nfs.c,v 1.19 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ntp.c b/usr.sbin/tcpdump/print-ntp.c index f3ea0df5092..b67116183e5 100644 --- a/usr.sbin/tcpdump/print-ntp.c +++ b/usr.sbin/tcpdump/print-ntp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ntp.c,v 1.15 2009/10/27 23:59:55 deraadt Exp $ */ +/* $OpenBSD: print-ntp.c,v 1.16 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -25,7 +25,6 @@ * loosely based on print-bootp.c */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-null.c b/usr.sbin/tcpdump/print-null.c index 95b91ef47d3..f3187edd9c6 100644 --- a/usr.sbin/tcpdump/print-null.c +++ b/usr.sbin/tcpdump/print-null.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-null.c,v 1.20 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-null.c,v 1.21 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1991, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-ospf.c b/usr.sbin/tcpdump/print-ospf.c index 81e83e332f5..0730171314a 100644 --- a/usr.sbin/tcpdump/print-ospf.c +++ b/usr.sbin/tcpdump/print-ospf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ospf.c,v 1.18 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ospf.c,v 1.19 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1992, 1993, 1994, 1995, 1996, 1997 @@ -23,7 +23,6 @@ * OSPF support contributed by Jeffrey Honig (jch@mitchell.cit.cornell.edu) */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ospf6.c b/usr.sbin/tcpdump/print-ospf6.c index 98e759dcd95..fa60d90285b 100644 --- a/usr.sbin/tcpdump/print-ospf6.c +++ b/usr.sbin/tcpdump/print-ospf6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ospf6.c,v 1.7 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ospf6.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* @@ -26,7 +26,6 @@ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-pflog.c b/usr.sbin/tcpdump/print-pflog.c index 2df0e7d5f29..df7c3d2dc7e 100644 --- a/usr.sbin/tcpdump/print-pflog.c +++ b/usr.sbin/tcpdump/print-pflog.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-pflog.c,v 1.25 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-pflog.c,v 1.26 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1993, 1994, 1995, 1996 @@ -21,8 +21,7 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/types.h> -#include <sys/param.h> +#include <sys/param.h> /* MSIZE MAXCOMLEN */ #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-pfsync.c b/usr.sbin/tcpdump/print-pfsync.c index 0475fc05084..a418b98d967 100644 --- a/usr.sbin/tcpdump/print-pfsync.c +++ b/usr.sbin/tcpdump/print-pfsync.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-pfsync.c,v 1.39 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-pfsync.c,v 1.40 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2002 Michael Shalayeff @@ -26,12 +26,10 @@ * THE POSSIBILITY OF SUCH DAMAGE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> #include <sys/ioctl.h> -#include <sys/mbuf.h> #ifdef __STDC__ struct rtentry; diff --git a/usr.sbin/tcpdump/print-pim.c b/usr.sbin/tcpdump/print-pim.c index d0684327ca3..cb73669a82b 100644 --- a/usr.sbin/tcpdump/print-pim.c +++ b/usr.sbin/tcpdump/print-pim.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-pim.c,v 1.6 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-pim.c,v 1.7 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1995, 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ppp.c b/usr.sbin/tcpdump/print-ppp.c index 34f66e4505f..63c57f3ffdd 100644 --- a/usr.sbin/tcpdump/print-ppp.c +++ b/usr.sbin/tcpdump/print-ppp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ppp.c,v 1.27 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ppp.c,v 1.28 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1993, 1994, 1995, 1996, 1997 @@ -22,7 +22,6 @@ */ #ifdef PPP -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-raw.c b/usr.sbin/tcpdump/print-raw.c index 53bd247e32c..233293d198a 100644 --- a/usr.sbin/tcpdump/print-raw.c +++ b/usr.sbin/tcpdump/print-raw.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-raw.c,v 1.7 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-raw.c,v 1.8 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-rip.c b/usr.sbin/tcpdump/print-rip.c index 6957fe95128..f4973c14c4b 100644 --- a/usr.sbin/tcpdump/print-rip.c +++ b/usr.sbin/tcpdump/print-rip.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-rip.c,v 1.13 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-rip.c,v 1.14 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1989, 1990, 1991, 1993, 1994, 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-ripng.c b/usr.sbin/tcpdump/print-ripng.c index 3b845866618..9337cd9f61b 100644 --- a/usr.sbin/tcpdump/print-ripng.c +++ b/usr.sbin/tcpdump/print-ripng.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-ripng.c,v 1.3 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-ripng.c,v 1.4 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1989, 1990, 1991, 1993, 1994 @@ -23,7 +23,6 @@ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-rt6.c b/usr.sbin/tcpdump/print-rt6.c index cad4329ba5a..27e741284f1 100644 --- a/usr.sbin/tcpdump/print-rt6.c +++ b/usr.sbin/tcpdump/print-rt6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-rt6.c,v 1.4 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-rt6.c,v 1.5 2015/01/16 06:40:21 deraadt Exp $ */ /* @@ -24,7 +24,6 @@ #ifdef INET6 -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-skip.c b/usr.sbin/tcpdump/print-skip.c index 10ecd658ed9..8c123dd729d 100644 --- a/usr.sbin/tcpdump/print-skip.c +++ b/usr.sbin/tcpdump/print-skip.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-skip.c,v 1.4 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-skip.c,v 1.5 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1995 Sun Microsystems, Inc. @@ -24,7 +24,6 @@ * UPDATES, ENHANCEMENTS, OR MODIFICATIONS. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> diff --git a/usr.sbin/tcpdump/print-sl.c b/usr.sbin/tcpdump/print-sl.c index 3cd7f85a02c..a2a25298392 100644 --- a/usr.sbin/tcpdump/print-sl.c +++ b/usr.sbin/tcpdump/print-sl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-sl.c,v 1.17 2014/11/20 04:01:01 jsg Exp $ */ +/* $OpenBSD: print-sl.c,v 1.18 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1989, 1990, 1991, 1993, 1994, 1995, 1996, 1997 @@ -22,11 +22,9 @@ */ #ifdef HAVE_NET_SLIP_H -#include <sys/param.h> #include <sys/time.h> #include <sys/file.h> #include <sys/ioctl.h> -#include <sys/mbuf.h> #include <sys/socket.h> struct rtentry; @@ -45,6 +43,7 @@ struct rtentry; #include <netdb.h> #include <pcap.h> #include <stdio.h> +#include <limits.h> #include "interface.h" #include "addrtoname.h" diff --git a/usr.sbin/tcpdump/print-slow.c b/usr.sbin/tcpdump/print-slow.c index 70b729e871f..493927425ba 100644 --- a/usr.sbin/tcpdump/print-slow.c +++ b/usr.sbin/tcpdump/print-slow.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-slow.c,v 1.2 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-slow.c,v 1.3 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1998-2005 The TCPDUMP project @@ -19,7 +19,6 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-snmp.c b/usr.sbin/tcpdump/print-snmp.c index 0d80d15a6f8..d0bdb853f5d 100644 --- a/usr.sbin/tcpdump/print-snmp.c +++ b/usr.sbin/tcpdump/print-snmp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-snmp.c,v 1.17 2009/11/12 00:02:16 deraadt Exp $ */ +/* $OpenBSD: print-snmp.c,v 1.18 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1993, 1994, 1995, 1996, 1997 @@ -55,7 +55,6 @@ # @(#)snmp.awk.x 1.1 (LANL) 1/15/90 */ -#include <sys/param.h> #include <sys/time.h> #include <ctype.h> diff --git a/usr.sbin/tcpdump/print-stp.c b/usr.sbin/tcpdump/print-stp.c index 958e558466f..fbeea005ca6 100644 --- a/usr.sbin/tcpdump/print-stp.c +++ b/usr.sbin/tcpdump/print-stp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-stp.c,v 1.8 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-stp.c,v 1.9 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 2000 Jason L. Wright (jason@thought.net) @@ -30,7 +30,6 @@ * Pretty print 802.1D Bridge Protocol Data Units */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> #include <sys/file.h> diff --git a/usr.sbin/tcpdump/print-sunrpc.c b/usr.sbin/tcpdump/print-sunrpc.c index 73eefbd8163..d1be6d540f6 100644 --- a/usr.sbin/tcpdump/print-sunrpc.c +++ b/usr.sbin/tcpdump/print-sunrpc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-sunrpc.c,v 1.18 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-sunrpc.c,v 1.19 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1992, 1993, 1994, 1995, 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-tcp.c b/usr.sbin/tcpdump/print-tcp.c index 487241f5875..96730025ad7 100644 --- a/usr.sbin/tcpdump/print-tcp.c +++ b/usr.sbin/tcpdump/print-tcp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-tcp.c,v 1.31 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-tcp.c,v 1.32 2015/01/16 06:40:21 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/print-tftp.c b/usr.sbin/tcpdump/print-tftp.c index 2d23e71bc93..3e189a3058a 100644 --- a/usr.sbin/tcpdump/print-tftp.c +++ b/usr.sbin/tcpdump/print-tftp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-tftp.c,v 1.10 2009/10/27 23:59:57 deraadt Exp $ */ +/* $OpenBSD: print-tftp.c,v 1.11 2015/01/16 06:40:22 deraadt Exp $ */ /* * Copyright (c) 1990, 1991, 1993, 1994, 1995, 1996, 1997 @@ -23,7 +23,6 @@ * Format and print trivial file transfer protocol packets. */ -#include <sys/param.h> #include <sys/time.h> #include <netinet/in.h> diff --git a/usr.sbin/tcpdump/print-timed.c b/usr.sbin/tcpdump/print-timed.c index fa0713e9770..3542e96239e 100644 --- a/usr.sbin/tcpdump/print-timed.c +++ b/usr.sbin/tcpdump/print-timed.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-timed.c,v 1.5 2009/10/27 23:59:57 deraadt Exp $ */ +/* $OpenBSD: print-timed.c,v 1.6 2015/01/16 06:40:22 deraadt Exp $ */ /* * Copyright (c) 2000 Ben Smithurst <ben@scientia.demon.co.uk> @@ -29,7 +29,6 @@ #include "config.h" #endif -#include <sys/param.h> #include <sys/time.h> #include <netinet/in.h> diff --git a/usr.sbin/tcpdump/print-udp.c b/usr.sbin/tcpdump/print-udp.c index 70283cf7626..d179b3e04a6 100644 --- a/usr.sbin/tcpdump/print-udp.c +++ b/usr.sbin/tcpdump/print-udp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-udp.c,v 1.37 2014/08/14 12:44:44 mpi Exp $ */ +/* $OpenBSD: print-udp.c,v 1.38 2015/01/16 06:40:22 deraadt Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996 @@ -21,7 +21,6 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#include <sys/param.h> #include <sys/time.h> #include <sys/socket.h> diff --git a/usr.sbin/tcpdump/privsep.c b/usr.sbin/tcpdump/privsep.c index e584e57c4aa..237af086a13 100644 --- a/usr.sbin/tcpdump/privsep.c +++ b/usr.sbin/tcpdump/privsep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: privsep.c,v 1.30 2011/09/22 09:12:30 stsp Exp $ */ +/* $OpenBSD: privsep.c,v 1.31 2015/01/16 06:40:22 deraadt Exp $ */ /* * Copyright (c) 2003 Can Erkin Acar @@ -411,7 +411,7 @@ impl_init_done(int fd, int *bpfd) static void impl_gethostbyaddr(int fd) { - char hostname[MAXHOSTNAMELEN]; + char hostname[HOST_NAME_MAX+1]; size_t hostname_len; int addr_af; struct hostent *hp; @@ -434,7 +434,7 @@ static void impl_ether_ntohost(int fd) { struct ether_addr ether; - char hostname[MAXHOSTNAMELEN]; + char hostname[HOST_NAME_MAX+1]; logmsg(LOG_DEBUG, "[priv]: msg PRIV_ETHER_NTOHOST received"); diff --git a/usr.sbin/tcpdump/smbutil.c b/usr.sbin/tcpdump/smbutil.c index a87def67f25..7e4a01255e3 100644 --- a/usr.sbin/tcpdump/smbutil.c +++ b/usr.sbin/tcpdump/smbutil.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smbutil.c,v 1.8 2013/04/16 18:10:24 deraadt Exp $ */ +/* $OpenBSD: smbutil.c,v 1.9 2015/01/16 06:40:22 deraadt Exp $ */ /* Copyright (C) Andrew Tridgell 1995-1999 @@ -11,7 +11,6 @@ #include "config.h" #endif -#include <sys/param.h> #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> |