Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-6-0]: src/external/bsd/tcpdump Apply patch (requested by spz in t...



details:   https://anonhg.NetBSD.org/src/rev/d8de497e2bc3
branches:  netbsd-6-0
changeset: 775178:d8de497e2bc3
user:      snj <snj%NetBSD.org@localhost>
date:      Sun Feb 19 17:44:39 2017 +0000

description:
Apply patch (requested by spz in ticket #1436):
Adjust for older libpcap in netbsd-6*

diffstat:

 external/bsd/tcpdump/dist/tcpdump.c   |  8 ++++++--
 external/bsd/tcpdump/include/config.h |  6 +++---
 2 files changed, 9 insertions(+), 5 deletions(-)

diffs (67 lines):

diff -r d59b82696891 -r d8de497e2bc3 external/bsd/tcpdump/dist/tcpdump.c
--- a/external/bsd/tcpdump/dist/tcpdump.c       Sun Feb 19 07:58:50 2017 +0000
+++ b/external/bsd/tcpdump/dist/tcpdump.c       Sun Feb 19 17:44:39 2017 +0000
@@ -30,7 +30,7 @@
 static const char copyright[] _U_ =
     "@(#) Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 2000\n\
 The Regents of the University of California.  All rights reserved.\n";
-__RCSID("$NetBSD: tcpdump.c,v 1.3.12.1 2017/02/19 07:35:25 snj Exp $");
+__RCSID("$NetBSD: tcpdump.c,v 1.3.12.2 2017/02/19 17:44:39 snj Exp $");
 #endif
 
 /*
@@ -156,8 +156,8 @@
 static int Iflag;                      /* rfmon (monitor) mode */
 #ifdef HAVE_PCAP_SET_TSTAMP_TYPE
 static int Jflag;                      /* list available time stamp types */
+static int jflag = -1;                 /* packet time stamp source */
 #endif
-static int jflag = -1;                 /* packet time stamp source */
 static int pflag;                      /* don't go promiscuous */
 #ifdef HAVE_PCAP_SETDIRECTION
 static int Qflag = -1;                 /* restrict captured packet by send/receive direction */
@@ -166,7 +166,9 @@
 static int Wflag;                      /* recycle output files after this number of files */
 static int WflagChars;
 static char *zflag = NULL;             /* compress each savefile using a specified command (like gzip or bzip2) */
+#ifdef HAVE_PCAP_SET_IMMEDIATE_MODE
 static int immediate_mode;
+#endif
 
 static int infodelay;
 static int infoprint;
@@ -190,7 +192,9 @@
 static RETSIGTYPE child_cleanup(int);
 static void print_version(void);
 static void print_usage(void);
+#ifdef HAVE_PCAP_SET_TSTAMP_TYPE
 static void show_tstamp_types_and_exit(pcap_t *, const char *device) __attribute__((noreturn));
+#endif
 static void show_dlts_and_exit(pcap_t *, const char *device) __attribute__((noreturn));
 #ifdef HAVE_PCAP_FINDALLDEVS
 static void show_devices_and_exit (void) __attribute__((noreturn));
diff -r d59b82696891 -r d8de497e2bc3 external/bsd/tcpdump/include/config.h
--- a/external/bsd/tcpdump/include/config.h     Sun Feb 19 07:58:50 2017 +0000
+++ b/external/bsd/tcpdump/include/config.h     Sun Feb 19 17:44:39 2017 +0000
@@ -146,7 +146,7 @@
 #define HAVE_PCAP_SET_DATALINK 1
 
 /* Define to 1 if you have the `pcap_set_immediate_mode' function. */
-#define HAVE_PCAP_SET_IMMEDIATE_MODE 1
+/* #undef HAVE_PCAP_SET_IMMEDIATE_MODE */
 
 /* Define to 1 if you have the `pcap_set_optimizer_debug' function. */
 /* #undef HAVE_PCAP_SET_OPTIMIZER_DEBUG */
@@ -155,10 +155,10 @@
 /* #undef HAVE_PCAP_SET_PARSER_DEBUG */
 
 /* Define to 1 if you have the `pcap_set_tstamp_precision' function. */
-#define HAVE_PCAP_SET_TSTAMP_PRECISION 1
+/* #undef HAVE_PCAP_SET_TSTAMP_PRECISION */
 
 /* Define to 1 if you have the `pcap_set_tstamp_type' function. */
-#define HAVE_PCAP_SET_TSTAMP_TYPE 1
+/* #undef HAVE_PCAP_SET_TSTAMP_TYPE */
 
 /* Define to 1 if you have the <pcap/usb.h> header file. */
 /* #undef HAVE_PCAP_USB_H */



Home | Main Index | Thread Index | Old Index