summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKurt Korbatits <kurt.korbatits@nokia.com>2012-01-25 07:10:47 +1000
committerQt by Nokia <qt-info@nokia.com>2012-02-02 01:56:03 +0100
commitaa5ff684769f46f5f1a835a937d3f164c560a144 (patch)
tree1b6fa5472b490587cd4238ea886cbb209fbdc12d
parent9cbbd38f22fe0aff72599583c7702f88195a7607 (diff)
qopenglcontext not checking for null and failing with platform minimal
- The minimal platform plugin returns null and was causing segfault. Change-Id: Ied262692f77e9801c3d3451de7f21539f7686ca4 Reviewed-by: Kurt Korbatits <kurt.korbatits@nokia.com> Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
-rw-r--r--src/gui/kernel/qopenglcontext.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/kernel/qopenglcontext.cpp b/src/gui/kernel/qopenglcontext.cpp
index ed7bb5d4b7..f6481d3bb0 100644
--- a/src/gui/kernel/qopenglcontext.cpp
+++ b/src/gui/kernel/qopenglcontext.cpp
@@ -168,6 +168,8 @@ bool QOpenGLContext::create()
Q_D(QOpenGLContext);
d->platformGLContext = QGuiApplicationPrivate::platformIntegration()->createPlatformOpenGLContext(this);
+ if (!d->platformGLContext)
+ return false;
d->platformGLContext->setContext(this);
if (!d->platformGLContext->isSharing())
d->shareContext = 0;