]> The Tcpdump Group git mirrors - tcpdump/commitdiff
include string.h for memcpy/memset.
authoritojun <itojun>
Tue, 3 Oct 2000 04:19:07 +0000 (04:19 +0000)
committeritojun <itojun>
Tue, 3 Oct 2000 04:19:07 +0000 (04:19 +0000)
on some architecutrees, sizeof(void *) > sizeof(int).   don't try to cast
pointer to int to check alignment issues.

print-ip6.c
print-rip.c
print-token.c
print-udp.c

index b8c9ccfd7c6a2a0c48586180c06fbb390bc20f28..e7b53fe66e657351c32018c9d418a526729b99a8 100644 (file)
@@ -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 <stdio.h>
 #include <stdlib.h>
 #include <unistd.h>
+#include <string.h>
 
 #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)
index 5894eba1fe948e017d0d4721728632aa2f7c6ffe..7237990c918be2fd22003fba642a88cb6cae571b 100644 (file)
@@ -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 <stdio.h>
 #include <ctype.h>
+#include <string.h>
 
 #include "interface.h"
 #include "addrtoname.h"
index 0c076d8e6a550f360f54c02b3e73a5161a3e2705..8c5b63a1da93b6327decf48bc39156a969912ab3 100644 (file)
@@ -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 <pcap.h>
 #include <stdio.h>
+#include <string.h>
 
 #include "interface.h"
 #include "addrtoname.h"
index 1b6a90adb26903d3b1f92ab15686e010887adff8..d7eec1d9d8943319d7822d2b2e79d548137b0f56 100644 (file)
@@ -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 <rpc/rpc.h>
 
 #include <stdio.h>
+#include <string.h>
 
 #ifdef INET6
 #include <netinet/ip6.h>