summaryrefslogtreecommitdiff
path: root/dbus
diff options
context:
space:
mode:
authorMatt Fischer <matt.fischer@garmin.com>2013-11-07 18:00:46 -0600
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2013-11-27 14:29:04 +0000
commiteca9a5a29e287478625310630cecda8cc29310d8 (patch)
treeca9e92f888705742f4861c14462986770c31cbca /dbus
parent6173ba221a4ed16892cc1b7a794cdac464de2dd2 (diff)
downloaddbus-eca9a5a29e287478625310630cecda8cc29310d8.tar.gz
Fix for MinGW build
dbus-sysdeps-win.c makes use of a constant called PROCESS_QUERY_LIMITED_INFORMATION, which was added after Windows XP. There is code present to make sure the constant is not used when running on an XP system, but the constant is still required at build time. Unfortunately, the Windows headers provided by MinGW are old enough that they do not contain this constant, so building with MinGW fails. This patch adds a definition for the constant if one is not already present. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=71366 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk> Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de> [altered comment to specify MinGW32 < 4, since mingw-w64 and MinGW 4.0+ do have this constant -smcv]
Diffstat (limited to 'dbus')
-rw-r--r--dbus/dbus-sysdeps-win.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/dbus/dbus-sysdeps-win.c b/dbus/dbus-sysdeps-win.c
index 1c974c50..74a4e84e 100644
--- a/dbus/dbus-sysdeps-win.c
+++ b/dbus/dbus-sysdeps-win.c
@@ -81,6 +81,11 @@ extern BOOL WINAPI ConvertSidToStringSidA (PSID Sid, LPSTR *StringSid);
#define O_BINARY 0
#endif
+#ifndef PROCESS_QUERY_LIMITED_INFORMATION
+/* MinGW32 < 4 does not define this value in its headers */
+#define PROCESS_QUERY_LIMITED_INFORMATION (0x1000)
+#endif
+
typedef int socklen_t;