From f718728567568454cecaa9810b1f2c029a002fd7 Mon Sep 17 00:00:00 2001 From: Jan-Arve Saether Date: Tue, 20 Dec 2011 13:32:01 +0100 Subject: [PATCH] Do not crash in the windows accessibility bridge If the object did not have a QAccessibleInterface subclass it would crash in the windows accessibility bridge. Change-Id: I931d69466a5a74a87f1c1c577fb1c918dcc8accf Reviewed-by: Frederik Gladhorn --- src/plugins/platforms/windows/qwindowsaccessibility.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/platforms/windows/qwindowsaccessibility.cpp b/src/plugins/platforms/windows/qwindowsaccessibility.cpp index 53d7b33..daf30ce 100644 --- a/src/plugins/platforms/windows/qwindowsaccessibility.cpp +++ b/src/plugins/platforms/windows/qwindowsaccessibility.cpp @@ -1404,7 +1404,7 @@ void QWindowsAccessibility::notifyAccessibilityUpdate(QObject *o, int who, QAcce // An event has to be associated with a window, // so find the first parent that is a widget and that has a WId QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(o); - QWindow *window = window_helper(iface); + QWindow *window = iface ? window_helper(iface) : 0; if (!window) { window = QGuiApplication::activeWindow(); -- 2.7.4