aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2017-11-08 01:05:24 -0800
committerGuy Harris <guy@alum.mit.edu>2017-11-08 01:05:24 -0800
commite514827cfa6c47efe59cf42edcf0ed288318caa2 (patch)
tree292d6a02153136cd6fa872940c0bee9d616531ca
parent64e48543f99b4f504bdef94fdf8a1296a6ec3c6a (diff)
Include portability.h when we need strdup().
-rw-r--r--tests/capturetest.c8
-rw-r--r--tests/opentest.c8
-rw-r--r--tests/threadsignaltest.c4
3 files changed, 16 insertions, 4 deletions
diff --git a/tests/capturetest.c b/tests/capturetest.c
index a431cbc0..c94564d6 100644
--- a/tests/capturetest.c
+++ b/tests/capturetest.c
@@ -31,9 +31,9 @@ The Regents of the University of California. All rights reserved.\n";
#include <stdarg.h>
#include <limits.h>
#ifdef _WIN32
-#include "getopt.h"
+ #include "getopt.h"
#else
-#include <unistd.h>
+ #include <unistd.h>
#endif
#include <errno.h>
#include <sys/types.h>
@@ -42,6 +42,10 @@ The Regents of the University of California. All rights reserved.\n";
#include "pcap/funcattrs.h"
+#ifdef _WIN32
+ #include "portability.h"
+#endif
+
static char *program_name;
/* Forwards */
diff --git a/tests/opentest.c b/tests/opentest.c
index c81e8d90..79c9c941 100644
--- a/tests/opentest.c
+++ b/tests/opentest.c
@@ -31,14 +31,18 @@ The Regents of the University of California. All rights reserved.\n";
#include <string.h>
#include <stdarg.h>
#ifdef _WIN32
-#include "getopt.h"
+ #include "getopt.h"
#else
-#include <unistd.h>
+ #include <unistd.h>
#endif
#include <errno.h>
#include "pcap/funcattrs.h"
+#ifdef _WIN32
+ #include "portability.h"
+#endif
+
#define MAXIMUM_SNAPLEN 65535
static char *program_name;
diff --git a/tests/threadsignaltest.c b/tests/threadsignaltest.c
index 4fcdd353..d4ba1e8e 100644
--- a/tests/threadsignaltest.c
+++ b/tests/threadsignaltest.c
@@ -40,6 +40,10 @@ The Regents of the University of California. All rights reserved.\n";
#include "pcap/funcattrs.h"
+#ifdef _WIN32
+ #include "portability.h"
+#endif
+
static char *program_name;
/* Forwards */