From 8a865e10a636f9d722f493a83e631651427dcc06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Fri, 24 Jan 2014 01:14:03 +0100 Subject: [PATCH] Fix version string comparison on desktop GL. I should really read the specs more carefully, this seems to be a very dark corner of desktop/ES compatibility. --- src/Magnum/Context.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Magnum/Context.cpp b/src/Magnum/Context.cpp index eb8d2e3b8..8771da18a 100644 --- a/src/Magnum/Context.cpp +++ b/src/Magnum/Context.cpp @@ -320,7 +320,7 @@ Context::Context() { const std::string version = versionString(); #ifndef MAGNUM_TARGET_GLES - if(version.find("OpenGL 2.1") != std::string::npos) + if(version.compare(0, 4, "2.1 ") == 0) #else if(version.find("OpenGL ES 2.0") != std::string::npos) #endif