summaryrefslogtreecommitdiff
path: root/java/jxgrabkey/files/patch-warnings
diff options
context:
space:
mode:
Diffstat (limited to 'java/jxgrabkey/files/patch-warnings')
-rw-r--r--java/jxgrabkey/files/patch-warnings24
1 files changed, 24 insertions, 0 deletions
diff --git a/java/jxgrabkey/files/patch-warnings b/java/jxgrabkey/files/patch-warnings
new file mode 100644
index 000000000000..fed1556455b8
--- /dev/null
+++ b/java/jxgrabkey/files/patch-warnings
@@ -0,0 +1,24 @@
+--- JXGrabKey/C++/src/JXGrabKey.cpp 2010-02-28 10:11:49.000000000 -0500
++++ JXGrabKey/C++/src/JXGrabKey.cpp 2016-06-30 03:15:41.718599000 -0400
+@@ -24,4 +24,5 @@
+ #include <X11/Xlib.h>
+ #include <X11/keysym.h>
++#include <X11/XKBlib.h>
+
+ #include <pthread.h>
+@@ -319,5 +320,5 @@
+
+ XSetErrorHandler((XErrorHandler) xErrorHandler);
+- pthread_spin_init(&x_lock, NULL); // init here bcoz of the returns
++ pthread_spin_init(&x_lock, PTHREAD_PROCESS_SHARED); // init here bcoz of the returns
+
+ doListen = true;
+@@ -347,6 +348,6 @@
+ << keys.at(i).id
+ << "; type = KeyPress; x11Keycode = '"
+- << XKeysymToString(XKeycodeToKeysym(dpy,
+- ev.xkey.keycode, 0)) << "' (0x"
++ << XKeysymToString(XkbKeycodeToKeysym(dpy,
++ ev.xkey.keycode, 0, 0)) << "' (0x"
+ << std::hex << ev.xkey.keycode
+ << "); x11Mask = 0x" << std::hex