diff options
author | ulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7> | 2006-02-17 02:18:48 +0000 |
---|---|---|
committer | ulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7> | 2006-02-17 02:18:48 +0000 |
commit | 4af29c9503dd08e445085314987123ac22a70579 (patch) | |
tree | 8dd5dd504a3c13ed7cd5cd018bca2736e2bb1467 /capture_sync.c | |
parent | 15bdfbb17971f84a84c7e7cbb6d06caf21b85f02 (diff) |
remove dependencies to pcap.h, so getting an idea what needs to be done by dumpcap in addition to the things already done now
various dumpcap related code cleanup: mainly #include's and capture engine related stuff
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@17327 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'capture_sync.c')
-rw-r--r-- | capture_sync.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/capture_sync.c b/capture_sync.c index e013f699ea..6cb53e8ae7 100644 --- a/capture_sync.c +++ b/capture_sync.c @@ -28,8 +28,6 @@ #ifdef HAVE_LIBPCAP -#include <pcap.h> - #include <glib.h> #include <stdio.h> #include <ctype.h> @@ -41,10 +39,16 @@ #include <signal.h> +#ifdef _WIN32 +#include <fcntl.h> +#endif + #ifdef HAVE_SYS_WAIT_H # include <sys/wait.h> #endif +#include "capture-pcap-util.h" + #ifndef _WIN32 /* * Define various POSIX macros (and, in the case of WCOREDUMP, non-POSIX @@ -353,7 +357,7 @@ sync_pipe_start(capture_options *capture_opts) { if (capture_opts->linktype != -1) { argv = sync_pipe_add_arg(argv, &argc, "-y"); #ifdef HAVE_PCAP_DATALINK_VAL_TO_NAME - g_snprintf(ssnap, ARGV_NUMBER_LEN, "%s",pcap_datalink_val_to_name(capture_opts->linktype)); + g_snprintf(ssnap, ARGV_NUMBER_LEN, "%s",linktype_val_to_name(capture_opts->linktype)); #else /* XXX - just treat it as a number */ g_snprintf(ssnap, ARGV_NUMBER_LEN, "%d",capture_opts->linktype); @@ -472,6 +476,7 @@ sync_pipe_start(capture_options *capture_opts) { si.hStdInput = signal_pipe_read; si.hStdOutput = sync_pipe_write; si.hStdError = sync_pipe_write; + /*si.hStdError = (HANDLE) _get_osfhandle(2);*/ #endif g_string_append(args, exename); |