From 42eb50c1e508d12e8439ae4962ab5aa935ec4574 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mika=20Isoj=C3=A4rvi?= Date: Fri, 24 Oct 2014 10:58:07 +0300 Subject: [PATCH] Fix EGL_CONTEXT_CLIENT_VERSION check. Check that EGL_CONTEXT_CLIENT_VERSION is version that supports version used when creating context instead of requiring it to be exactly same. Bug: 18329517 Change-Id: I072a5796d92450b29e82655ea840c3b67ec8eea9 (cherry picked from commit 2b5718821a9ec271f25bcac0569c6e1c2dcf33eb) --- modules/egl/teglQueryContextTests.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/egl/teglQueryContextTests.cpp b/modules/egl/teglQueryContextTests.cpp index c6edb9d..3f3fe2b 100644 --- a/modules/egl/teglQueryContextTests.cpp +++ b/modules/egl/teglQueryContextTests.cpp @@ -404,7 +404,8 @@ public: { const EGLint clientVersion = getContextAttrib(display, context, EGL_CONTEXT_CLIENT_VERSION); - if (info.clientType == EGL_OPENGL_ES_API && clientVersion != info.clientVersion) + // \todo [2014-10-21 mika] Query actual supported api version from client api to make this check stricter. + if (info.clientType == EGL_OPENGL_ES_API && ((info.clientVersion == 1 && clientVersion != 1) || clientVersion < info.clientVersion)) { log << TestLog::Message << " Fail, client API version doesn't match." << TestLog::EndMessage; m_testCtx.setTestResult(QP_TEST_RESULT_FAIL, "Invalid client API version"); -- 2.7.4