From febfc92d3ff37535b920f485e6491cf072700728 Mon Sep 17 00:00:00 2001 From: itojun Date: Tue, 3 Oct 2000 04:19:07 +0000 Subject: [PATCH] include string.h for memcpy/memset. on some architecutrees, sizeof(void *) > sizeof(int). don't try to cast pointer to int to check alignment issues. --- print-ip6.c | 5 +++-- print-rip.c | 3 ++- print-token.c | 3 ++- print-udp.c | 3 ++- 4 files changed, 9 insertions(+), 5 deletions(-) diff --git a/print-ip6.c b/print-ip6.c index b8c9ccfd..e7b53fe6 100644 --- a/print-ip6.c +++ b/print-ip6.c @@ -21,7 +21,7 @@ #ifndef lint static const char rcsid[] = - "@(#) $Header: /tcpdump/master/tcpdump/print-ip6.c,v 1.12 2000-09-29 04:58:41 guy Exp $"; + "@(#) $Header: /tcpdump/master/tcpdump/print-ip6.c,v 1.13 2000-10-03 04:19:07 itojun Exp $"; #endif #ifdef HAVE_CONFIG_H @@ -40,6 +40,7 @@ static const char rcsid[] = #include #include #include +#include #include "interface.h" #include "addrtoname.h" @@ -67,7 +68,7 @@ ip6_print(register const u_char *bp, register int length) * This will never happen with BPF. It does happen raw packet * dumps from -r. */ - if ((int)ip6 & 15) { + if ((u_long)ip6 & 15) { static u_char *abuf; if (abuf == NULL) diff --git a/print-rip.c b/print-rip.c index 5894eba1..7237990c 100644 --- a/print-rip.c +++ b/print-rip.c @@ -21,7 +21,7 @@ #ifndef lint static const char rcsid[] = - "@(#) $Header: /tcpdump/master/tcpdump/print-rip.c,v 1.46 2000-09-29 04:58:47 guy Exp $ (LBL)"; + "@(#) $Header: /tcpdump/master/tcpdump/print-rip.c,v 1.47 2000-10-03 04:19:07 itojun Exp $ (LBL)"; #endif #ifdef HAVE_CONFIG_H @@ -36,6 +36,7 @@ static const char rcsid[] = #include #include +#include #include "interface.h" #include "addrtoname.h" diff --git a/print-token.c b/print-token.c index 0c076d8e..8c5b63a1 100644 --- a/print-token.c +++ b/print-token.c @@ -25,7 +25,7 @@ */ #ifndef lint static const char rcsid[] = - "@(#) $Header: /tcpdump/master/tcpdump/print-token.c,v 1.6 2000-09-29 04:58:52 guy Exp $"; + "@(#) $Header: /tcpdump/master/tcpdump/print-token.c,v 1.7 2000-10-03 04:19:08 itojun Exp $"; #endif #ifdef HAVE_CONFIG_H @@ -43,6 +43,7 @@ struct rtentry; #include #include +#include #include "interface.h" #include "addrtoname.h" diff --git a/print-udp.c b/print-udp.c index 1b6a90ad..d7eec1d9 100644 --- a/print-udp.c +++ b/print-udp.c @@ -21,7 +21,7 @@ #ifndef lint static const char rcsid[] = - "@(#) $Header: /tcpdump/master/tcpdump/print-udp.c,v 1.81 2000-10-03 02:55:02 itojun Exp $ (LBL)"; + "@(#) $Header: /tcpdump/master/tcpdump/print-udp.c,v 1.82 2000-10-03 04:19:08 itojun Exp $ (LBL)"; #endif #ifdef HAVE_CONFIG_H @@ -42,6 +42,7 @@ static const char rcsid[] = #include #include +#include #ifdef INET6 #include