summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2013-09-02 17:39:37 +0100
committerRalf Habacker <ralf.habacker@freenet.de>2013-10-26 10:07:04 +0200
commit41412e04b1a99707456cd205333fd0aa79f172ac (patch)
treee375b1ad7f17afb8248babf9447cb4e47c59788c
parent6a7942f29cd92ec5162e5cc6fbb566101a280184 (diff)
downloaddbus-41412e04b1a99707456cd205333fd0aa79f172ac.tar.gz
dbus-sysdeps-win.h: do not redefine _inline if not already defined
mingw-w64 3.0~svn5915 defines it to __inline, provoking a redefinition warning. It looks as though this was probably just a workaround for a broken mingw version of wspiapi.h anyway?
-rw-r--r--dbus/dbus-sysdeps-win.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/dbus/dbus-sysdeps-win.c b/dbus/dbus-sysdeps-win.c
index 1c974c50..5d0ea0fb 100644
--- a/dbus/dbus-sysdeps-win.c
+++ b/dbus/dbus-sysdeps-win.c
@@ -77,6 +77,18 @@ extern BOOL WINAPI ConvertSidToStringSidA (PSID Sid, LPSTR *StringSid);
#include <ws2tcpip.h>
#endif
+#ifdef HAVE_WSPIAPI_H
+// needed for w2k compatibility (getaddrinfo/freeaddrinfo/getnameinfo)
+# ifdef __GNUC__
+# ifndef _inline
+# define _inline
+# endif
+# include "wspiapi.h"
+# else
+# include <wspiapi.h>
+# endif
+#endif // HAVE_WSPIAPI_H
+
#ifndef O_BINARY
#define O_BINARY 0
#endif