diff options
author | Tim Blechmann <tim@klingt.org> | 2016-06-10 09:54:09 +0200 |
---|---|---|
committer | Tim Blechmann <tim@klingt.org> | 2016-07-12 07:33:31 +0000 |
commit | 8ba3fee61030e54ee1bc79c15059170be5bc2add (patch) | |
tree | fc974ffd210f3cb78c588b10f48e0ad405f5fefe /src | |
parent | 4f6c6ef65f7f9f44590b2b615aa98f64d04aeddf (diff) |
QWindowsOpenGLTester: fall back to built-in blacklist if buglist file cannot be resolved
if the environment variable is set, but the buglist file cannot be found,
we should fall back to the built-in buglist instead of not using any.
Change-Id: I370a1f21238efd155b46f0e7071734f5d3c6c343
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/platforms/windows/qwindowsopengltester.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/plugins/platforms/windows/qwindowsopengltester.cpp b/src/plugins/platforms/windows/qwindowsopengltester.cpp index 4ca7f0e413..c24e0ba0ae 100644 --- a/src/plugins/platforms/windows/qwindowsopengltester.cpp +++ b/src/plugins/platforms/windows/qwindowsopengltester.cpp @@ -246,15 +246,16 @@ QWindowsOpenGLTester::Renderers QWindowsOpenGLTester::detectSupportedRenderers(c if (!glesOnly && testDesktopGL()) result |= QWindowsOpenGLTester::DesktopGl; - QSet<QString> features; const char bugListFileVar[] = "QT_OPENGL_BUGLIST"; + QString buglistFileName = QStringLiteral(":/qt-project.org/windows/openglblacklists/default.json"); + if (qEnvironmentVariableIsSet(bugListFileVar)) { const QString fileName = resolveBugListFile(QFile::decodeName(qgetenv(bugListFileVar))); if (!fileName.isEmpty()) - features = QOpenGLConfig::gpuFeatures(qgpu, fileName); - } else { - features = QOpenGLConfig::gpuFeatures(qgpu, QStringLiteral(":/qt-project.org/windows/openglblacklists/default.json")); + buglistFileName = fileName; } + + QSet<QString> features = QOpenGLConfig::gpuFeatures(qgpu, buglistFileName); qCDebug(lcQpaGl) << "GPU features:" << features; if (features.contains(QStringLiteral("disable_desktopgl"))) { // Qt-specific |