aboutsummaryrefslogtreecommitdiffstats
path: root/editcap.c
diff options
context:
space:
mode:
authorwmeier <wmeier@f5534014-38df-0310-8fa8-9805f1628bb7>2008-10-24 00:42:09 +0000
committerwmeier <wmeier@f5534014-38df-0310-8fa8-9805f1628bb7>2008-10-24 00:42:09 +0000
commitd7d039675e3ae6a2550499fe38f7df29c4c91b67 (patch)
tree9dba16a45db59ebe1b10965d38f3844a27cc911f /editcap.c
parentdc41ee4f7781c1bdd95eb94b410f0896e57fdeb7 (diff)
Windows build: #include winsock2.h only when needed.
#include winsock2.h pulls in about 90 distinct .h files and about 140 total .h files. Currently winsock2.h is (mostly unnecessarily) included for each dissector via packet.h/wtap.h. This patch removes #include winsock2.h from wtap.h and then includes winsock2.h (or windows.h) in the few specific places required. With this patch, my Windows Wireshark build takes about 30% less time. git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@26535 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'editcap.c')
-rw-r--r--editcap.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/editcap.c b/editcap.c
index 84ecd0a727..88a5e16ed3 100644
--- a/editcap.c
+++ b/editcap.c
@@ -48,6 +48,9 @@
#ifdef _WIN32
#include <process.h> /* getpid */
+#ifdef HAVE_WINSOCK2_H
+#include <winsock2.h>
+#endif
#endif
#ifdef NEED_STRPTIME_H