From c9002ab7eec1649d700865eac418f1f5d3b0d1a2 Mon Sep 17 00:00:00 2001 From: Alvin Wong Date: Thu, 25 Apr 2019 19:08:04 +0800 Subject: Fix QOpenGLDebugLogger crash on ANGLE The helper in QOpenGLDebugLogger did not account for the extra "KHR" suffix in the function names and results in a crash when ANGLE is being used. This commit fixes this issue. Change-Id: I439d8bfc53b010be5410286b86c090aff171aaef Fixes: QTBUG-62070 Reviewed-by: Giuseppe D'Angelo --- src/gui/opengl/qopengldebug.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/gui/opengl') diff --git a/src/gui/opengl/qopengldebug.cpp b/src/gui/opengl/qopengldebug.cpp index 2e628a2bd5..9f1bb76869 100644 --- a/src/gui/opengl/qopengldebug.cpp +++ b/src/gui/opengl/qopengldebug.cpp @@ -1366,7 +1366,7 @@ bool QOpenGLDebugLogger::initialize() #define GET_DEBUG_PROC_ADDRESS(procName) \ d->procName = reinterpret_cast< qt_ ## procName ## _t >( \ - d->context->getProcAddress(#procName) \ + d->context->getProcAddress(d->context->isOpenGLES() ? (#procName "KHR") : (#procName)) \ ); GET_DEBUG_PROC_ADDRESS(glDebugMessageControl); -- cgit v1.2.3