Actually, you only have monitor mode support if you have pcap_create() -
authorguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>
Wed, 25 Jan 2012 19:40:22 +0000 (19:40 +0000)
committerguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>
Wed, 25 Jan 2012 19:40:22 +0000 (19:40 +0000)
without pcap_create() and pcap_activate() you don't have any API to turn
it on.

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@40725 f5534014-38df-0310-8fa8-9805f1628bb7

capture_opts.c
capture_opts.h

index 0db1637c4de1bd9af704451085591fd61abd3df3..3990f2a0e742a6a434c0d0cf3e2c8bf24b59f813 100644 (file)
@@ -983,6 +983,8 @@ collect_ifaces(capture_options *capture_opts)
       interface_opts.promisc_mode = device.pmode;
 #if defined(_WIN32) || defined(HAVE_PCAP_CREATE)
       interface_opts.buffer_size =  device.buffer;
+#endif
+#ifdef HAVE_PCAP_CREATE
       interface_opts.monitor_mode = device.monitor_mode_enabled;
 #endif
       if (!device.local) {
index f8ed3cd1d8096781c3921325b6f2a317f3ea73c7..5e0d2e56ea1cfe05172522bf3757891b6f731ec2 100644 (file)
@@ -126,6 +126,8 @@ typedef struct interface_tag {
     gboolean local;
 #if defined(_WIN32) || defined(HAVE_PCAP_CREATE)
     gint buffer;
+#endif
+#ifdef HAVE_PCAP_CREATE
     gboolean monitor_mode_enabled;
     gboolean monitor_mode_supported;
 #endif