diff options
-rw-r--r-- | src/XIAllowEvents.c | 2 | ||||
-rw-r--r-- | src/XIGetDevFocus.c | 2 | ||||
-rw-r--r-- | src/XIGrabDevice.c | 2 | ||||
-rw-r--r-- | src/XIQueryDevice.c | 2 | ||||
-rw-r--r-- | src/XISetDevFocus.c | 2 |
5 files changed, 10 insertions, 0 deletions
diff --git a/src/XIAllowEvents.c b/src/XIAllowEvents.c index 7ae4119..75980a0 100644 --- a/src/XIAllowEvents.c +++ b/src/XIAllowEvents.c @@ -35,6 +35,8 @@ XIAllowEvents(Display *dpy, int deviceid, int event_mode, Time time) xXIAllowEventsReq *req; XExtDisplayInfo *extinfo = XInput_find_display(dpy); + + LockDisplay(dpy); if (_XiCheckExtInit(dpy, Dont_Check, extinfo) == -1) return (NoSuchExtension); diff --git a/src/XIGetDevFocus.c b/src/XIGetDevFocus.c index 32adfde..1381066 100644 --- a/src/XIGetDevFocus.c +++ b/src/XIGetDevFocus.c @@ -36,6 +36,8 @@ XIGetDeviceFocus(Display *dpy, int deviceid, Window *focus_return) xXIGetDeviceFocusReply reply; XExtDisplayInfo *extinfo = XInput_find_display(dpy); + + LockDisplay(dpy); if (_XiCheckExtInit(dpy, Dont_Check, extinfo) == -1) return (NoSuchExtension); diff --git a/src/XIGrabDevice.c b/src/XIGrabDevice.c index f97138c..bb668ee 100644 --- a/src/XIGrabDevice.c +++ b/src/XIGrabDevice.c @@ -41,6 +41,8 @@ XIGrabDevice(Display* dpy, int deviceid, Window grab_window, Time time, int len; XExtDisplayInfo *extinfo = XInput_find_display(dpy); + + LockDisplay(dpy); if (_XiCheckExtInit(dpy, Dont_Check, extinfo) == -1) return (NoSuchExtension); diff --git a/src/XIQueryDevice.c b/src/XIQueryDevice.c index 1e17ad0..2a07ce5 100644 --- a/src/XIQueryDevice.c +++ b/src/XIQueryDevice.c @@ -157,6 +157,8 @@ XIQueryDevice(Display *dpy, int deviceid, int *ndevices_return) char *buf; XExtDisplayInfo *extinfo = XInput_find_display(dpy); + + LockDisplay(dpy); if (_XiCheckExtInit(dpy, Dont_Check, extinfo) == -1) goto error; diff --git a/src/XISetDevFocus.c b/src/XISetDevFocus.c index fe08c1f..c394c02 100644 --- a/src/XISetDevFocus.c +++ b/src/XISetDevFocus.c @@ -35,6 +35,8 @@ XISetDeviceFocus(Display *dpy, int deviceid, Window focus, Time time) xXISetDeviceFocusReq *req; XExtDisplayInfo *extinfo = XInput_find_display(dpy); + + LockDisplay(dpy); if (_XiCheckExtInit(dpy, Dont_Check, extinfo) == -1) return (NoSuchExtension); |