diff options
Diffstat (limited to 'xorg-server/Xi/exevents.c')
-rw-r--r-- | xorg-server/Xi/exevents.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/xorg-server/Xi/exevents.c b/xorg-server/Xi/exevents.c index 40e03337d..7370a0bcf 100644 --- a/xorg-server/Xi/exevents.c +++ b/xorg-server/Xi/exevents.c @@ -54,6 +54,8 @@ SOFTWARE. #ifdef HAVE_DIX_CONFIG_H
#include <dix-config.h>
+#else
+#define XINPUT
#endif
#include "inputstr.h"
@@ -919,6 +921,7 @@ ProcessRawEvent(RawDeviceEvent *ev, DeviceIntPtr device) }
for (i = 0; i < screenInfo.numScreens; i++)
+ if (screenInfo.screens[i] && screenInfo.screens[i]->root)
DeliverEventsToWindow(device, screenInfo.screens[i]->root, xi, 1,
GetEventFilter(device, xi), NULL);
free(xi);
@@ -960,7 +963,7 @@ ProcessOtherEvent(InternalEvent *ev, DeviceIntPtr device) {
kbd = GetPairedDevice(device);
mouse = device;
- if (!kbd->key) /* can happen with floating SDs */
+ if (kbd && !kbd->key) /* can happen with floating SDs */
kbd = NULL;
} else
{
@@ -1018,6 +1021,8 @@ ProcessOtherEvent(InternalEvent *ev, DeviceIntPtr device) case ET_KeyRelease:
case ET_ProximityIn:
case ET_ProximityOut:
+ if (!device->spriteInfo->sprite)
+ return;
GetSpritePosition(device, &rootX, &rootY);
event->root_x = rootX;
event->root_y = rootY;
@@ -1694,6 +1699,10 @@ RecalculateDeviceDeliverableEvents(WindowPtr pWin) }
}
+#ifdef _MSC_VER
+#pragma warning(disable:4715) /* Not all control paths return a value */
+#endif
+
int
InputClientGone(WindowPtr pWin, XID id)
{
|