]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
wlantest: Comment out Linux packet socket from OS X build
authorJouni Malinen <j@w1.fi>
Sun, 5 Apr 2020 14:57:32 +0000 (17:57 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 5 Apr 2020 15:53:59 +0000 (18:53 +0300)
For now, allow wlantest to be built on OS X without support for
live sniffer capturing.

Signed-off-by: Jouni Malinen <j@w1.fi>
wlantest/monitor.c

index afcc3806ff2e3d0d4e1deb83bcc31bb0795f9b2e..f28708689ed93d0738a38a0ee4873d32f6bab00a 100644 (file)
@@ -7,14 +7,36 @@
  */
 
 #include "utils/includes.h"
+#ifndef __APPLE__
 #include <net/if.h>
 #include <netpacket/packet.h>
+#endif /* __APPLE__ */
 
 #include "utils/common.h"
 #include "utils/eloop.h"
 #include "wlantest.h"
 
 
+#ifdef __APPLE__
+
+int monitor_init(struct wlantest *wt, const char *ifname)
+{
+       return -1;
+}
+
+
+int monitor_init_wired(struct wlantest *wt, const char *ifname)
+{
+       return -1;
+}
+
+
+void monitor_deinit(struct wlantest *wt)
+{
+}
+
+#else /* __APPLE__ */
+
 static void monitor_read(int sock, void *eloop_ctx, void *sock_ctx)
 {
        struct wlantest *wt = eloop_ctx;
@@ -146,3 +168,5 @@ void monitor_deinit(struct wlantest *wt)
                wt->monitor_wired = -1;
        }
 }
+
+#endif /* __APPLE__ */