[Pkg-telepathy-commits] [libnice] 204/265: agent: Define IN6_ARE_ADDR_EQUAL macro when building under MinGW

Simon McVittie smcv at debian.org
Wed May 14 12:05:08 UTC 2014


This is an automated email from the git hooks/post-receive script.

smcv pushed a commit to branch debian
in repository libnice.

commit cee3641b3255b2fd564ed446d789554aefda7394
Author: Philip Withnall <philip.withnall at collabora.co.uk>
Date:   Thu Apr 3 12:22:27 2014 +0100

    agent: Define IN6_ARE_ADDR_EQUAL macro when building under MinGW
    
    Older versions of MinGW don’t define IN6_ARE_ADDR_EQUAL, as normally
    defined in netinet/in.h. Conditionally define it in address.c to fix the
    build on MinGW.
    
    MinGW has added support for the macro here:
    https://github.com/mirror/mingw-w64/commit/0f4899473c4ba2e34fa447b1931a04e38c1f105e
    
    Based on a patch originally by Luciana Fujii Pontello
    <luciana at fujii.eti.br>.
---
 agent/address.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/agent/address.c b/agent/address.c
index 9a7fe33..6e31c81 100644
--- a/agent/address.c
+++ b/agent/address.c
@@ -50,6 +50,14 @@
 #define inet_pton inet_pton_win32
 #define inet_ntop inet_ntop_win32
 
+/* Defined in recent versions of mingw:
+ * https://github.com/mirror/mingw-w64/commit/0f4899473c4ba2e34fa447b1931a04e38c1f105e
+ */
+#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
+
 
 static const char *
 inet_ntop_win32 (int af, const void *src, char *dst, socklen_t cnt)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-telepathy/libnice.git



More information about the Pkg-telepathy-commits mailing list