Check if the interface pointer is valid to avoid a potential crash.

Change-Id: I7e6634b799e551786d6cbc85e2d526b7874ada3d
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
This commit is contained in:
Jan Arve Saether 2013-02-06 10:23:24 +01:00 committed by The Qt Project
parent 20204fe58b
commit 7502a78388

View File

@ -1181,7 +1181,7 @@ void AtSpiAdaptor::notifyAboutCreation(const QAIPointer &interface) const
void AtSpiAdaptor::notifyAboutDestruction(const QAIPointer &interface) const void AtSpiAdaptor::notifyAboutDestruction(const QAIPointer &interface) const
{ {
if (!interface->isValid()) if (!interface || !interface->isValid())
return; return;
QAIPointer parent(interface->parent()); QAIPointer parent(interface->parent());