diff options
author | Jon TURNEY <jon.turney@dronecode.org.uk> | 2013-06-19 13:09:35 +0100 |
---|---|---|
committer | Jon TURNEY <jon.turney@dronecode.org.uk> | 2014-09-13 14:19:06 +0100 |
commit | 1d6334dd0ca99923b6b55c5c047ef6b5c325f66c (patch) | |
tree | 20918a6712e2f9f3d68e44cb82cd018e57cdd5cb /hw/xwin/winclipboard/thread.c | |
parent | 7ca93301940647219dbed2d14fcd3f37e49fb477 (diff) |
hw/xwin: Undefine _XSERVER64 in hw/xwin/winclipboard
Including any server header might define the macro _XSERVER64 on 64 bit
machines. That macro must _NOT_ be defined for Xlib client code, otherwise bad
things happen. So let's undef that macro if necessary.
Remove server directories from include path to ensure no server includes are
included
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Diffstat (limited to 'hw/xwin/winclipboard/thread.c')
-rw-r--r-- | hw/xwin/winclipboard/thread.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/hw/xwin/winclipboard/thread.c b/hw/xwin/winclipboard/thread.c index a124e3e90..c179e3f83 100644 --- a/hw/xwin/winclipboard/thread.c +++ b/hw/xwin/winclipboard/thread.c @@ -36,6 +36,15 @@ #define HAS_WINSOCK 1 #endif +/* + * Including any server header might define the macro _XSERVER64 on 64 bit machines. + * That macro must _NOT_ be defined for Xlib client code, otherwise bad things happen. + * So let's undef that macro if necessary. + */ +#ifdef _XSERVER64 +#undef _XSERVER64 +#endif + #include <assert.h> #include <unistd.h> #include <fcntl.h> |