diff options
-rw-r--r-- | src/gui/opengl/qopenglpaintengine.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/opengl/qopenglpaintengine.cpp b/src/gui/opengl/qopenglpaintengine.cpp index a9a4adaddc..4836dde343 100644 --- a/src/gui/opengl/qopenglpaintengine.cpp +++ b/src/gui/opengl/qopenglpaintengine.cpp @@ -2076,7 +2076,7 @@ bool QOpenGL2PaintEngineEx::begin(QPaintDevice *pdev) d->device->ensureActiveTarget(); - if (d->device->context() != QOpenGLContext::currentContext()) { + if (d->device->context() != QOpenGLContext::currentContext() || !d->device->context()) { qWarning("QPainter::begin(): QOpenGLPaintDevice's context needs to be current"); return false; } |