#ifndef lint
static const char rcsid[] =
- "@(#) $Header: /tcpdump/master/tcpdump/print-null.c,v 1.32 2000-09-23 08:03:39 guy Exp $ (LBL)";
+ "@(#) $Header: /tcpdump/master/tcpdump/print-null.c,v 1.38 2000-10-07 05:53:13 itojun Exp $ (LBL)";
#endif
#ifdef HAVE_CONFIG_H
struct mbuf;
struct rtentry;
-#include <net/if.h>
#include <netinet/in.h>
-#include <netinet/in_systm.h>
-#include <netinet/ip.h>
-#include <netinet/ip_var.h>
-#include <netinet/udp.h>
-#include <netinet/udp_var.h>
-#include <netinet/tcp.h>
#include <pcap.h>
#include <stdio.h>
#include <string.h>
-#ifdef INET6
-#include <netinet/ip6.h>
-#endif
-
#include "interface.h"
#include "addrtoname.h"
+#include "ip.h"
+#ifdef INET6
+#include "ip6.h"
+#endif
+
#ifndef AF_NS
#define AF_NS 6 /* XEROX NS protocols */
#endif
if (eflag)
null_print(p, ip, length);
- switch (ip->ip_v) {
+ switch (IP_V(ip)) {
case 4:
ip_print((const u_char *)ip, length);
break;
break;
#endif /* INET6 */
default:
- printf("ip v%d", ip->ip_v);
+ printf("ip v%d", IP_V(ip));
break;
}