diff options
-rw-r--r-- | src/plugins/platforms/webgl/qwebglcontext.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/platforms/webgl/qwebglcontext.cpp b/src/plugins/platforms/webgl/qwebglcontext.cpp index 9d48d74..07378a2 100644 --- a/src/plugins/platforms/webgl/qwebglcontext.cpp +++ b/src/plugins/platforms/webgl/qwebglcontext.cpp @@ -1570,6 +1570,8 @@ QWebGLFunctionCall *QWebGLContext::createEvent(const QString &functionName, bool auto context = QOpenGLContext::currentContext(); Q_ASSERT(context); const auto handle = static_cast<QWebGLContext *>(context->handle()); + if (!handle) + return nullptr; auto integrationPrivate = QWebGLIntegrationPrivate::instance(); const auto clientData = integrationPrivate->findClientData(handle->currentSurface()); if (!clientData || !clientData->socket |