summaryrefslogtreecommitdiffstats
path: root/src/openvg/qwindowsurface_vgegl.cpp
diff options
context:
space:
mode:
authorMiikka Heikkinen <miikka.heikkinen@digia.com>2010-03-09 15:02:25 +0200
committerMiikka Heikkinen <miikka.heikkinen@digia.com>2010-03-10 14:15:05 +0200
commitde66b772294e314828d85cb9cdd5db82221f317a (patch)
tree41a72d3ffd642c29acc510e435e9126629d2c272 /src/openvg/qwindowsurface_vgegl.cpp
parent8dd695793dd41dc57ded6506aadbd23786e11cf4 (diff)
Added check for null pointer in qt_vg_unregister_pixmap.
The method qt_vg_unregister_pixmap is sometimes called when the QVGSharedContext is already destroyed. Do not try to access it if it is null. Part of QtP delta reduction effort. Reviewed-by: Jason Barron
Diffstat (limited to 'src/openvg/qwindowsurface_vgegl.cpp')
-rw-r--r--src/openvg/qwindowsurface_vgegl.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/openvg/qwindowsurface_vgegl.cpp b/src/openvg/qwindowsurface_vgegl.cpp
index 9c445455f9..693312a8c8 100644
--- a/src/openvg/qwindowsurface_vgegl.cpp
+++ b/src/openvg/qwindowsurface_vgegl.cpp
@@ -177,7 +177,8 @@ void qt_vg_unregister_pixmap(QVGPixmapData *pd)
pd->prev->next = pd->next;
} else {
QVGSharedContext *shared = sharedContext();
- shared->firstPixmap = pd->next;
+ if (shared)
+ shared->firstPixmap = pd->next;
}
}