Windows headers do not define the IN6_ARE_ADDR_EQUAL macro. It needs
to be defined locally when building for WIN32 with IPv6 enabled.

Signed-off-by: Heiko Hund <heiko.h...@sophos.com>
---
 win32.h |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/win32.h b/win32.h
index d0ecc85..87d8ecc 100644
--- a/win32.h
+++ b/win32.h
@@ -41,6 +41,16 @@
  * development environment.
  */

+#ifdef USE_PF_INET6
+
+/* MSVC headers do not define this macro, so do it here */
+#ifndef IN6_ARE_ADDR_EQUAL
+#define IN6_ARE_ADDR_EQUAL(a,b) \
+  (memcmp ((const void*)(a), (const void*)(b), sizeof (struct in6_addr)) == 0)
+#endif
+
+#endif
+
 void init_win32 (void);
 void uninit_win32 (void);

-- 
1.7.5.4


Reply via email to