[vlc-devel] [PATCH] Work-around Mingw64 IN6_IS_ADDR_MULTICAST breakage
Jean-Baptiste Kempf
jb at videolan.org
Tue Oct 11 13:50:17 CEST 2016
Mingw-w64 is not defined the correct macro, as defined in POSIX spec
Mingw is fine.
Close #13071
---
include/vlc_fixups.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/include/vlc_fixups.h b/include/vlc_fixups.h
index 690daae..323ee47 100644
--- a/include/vlc_fixups.h
+++ b/include/vlc_fixups.h
@@ -384,6 +384,11 @@ struct if_nameindex
# define if_freenameindex(list) (void)0
#endif
+/* mingw-w64 has a broken IN6_IS_ADDR_MULTICAST macro */
+#if defined(_WIN32) && defined(__MINGW64_VERSION_MAJOR)
+# define IN6_IS_ADDR_MULTICAST(_addr) (((const u_char *) (_addr))[0] == 0xff)
+#endif
+
#ifndef HAVE_STRUCT_TIMESPEC
struct timespec {
time_t tv_sec; /* Seconds */
--
2.9.3
More information about the vlc-devel
mailing list