From b61d1417dc81761276b3bac44775141b3551ef4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20R=C3=B8dal?= Date: Mon, 13 Feb 2012 20:38:44 +0100 Subject: Prevent occasional crash in qwaylandinputdevice.cpp Change-Id: I86559add9925dad6aef530433dd92066f1708757 Reviewed-by: Laszlo Agocs --- src/plugins/platforms/wayland/qwaylandinputdevice.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/platforms/wayland/qwaylandinputdevice.cpp b/src/plugins/platforms/wayland/qwaylandinputdevice.cpp index ee4ffc1c..88b1bda0 100644 --- a/src/plugins/platforms/wayland/qwaylandinputdevice.cpp +++ b/src/plugins/platforms/wayland/qwaylandinputdevice.cpp @@ -268,7 +268,7 @@ void QWaylandInputDevice::inputHandleKey(void *data, QEvent::Type type; char s[2]; - if (window == NULL) { + if (window == NULL || !inputDevice->mXkb) { /* We destroyed the keyboard focus surface, but the server * didn't get the message yet. */ return; -- cgit v1.2.1