Bug 1394265 - Don't allow GL version <200. - r=daoshengmu
MozReview-Commit-ID: 8wD8uHFc5kY
--- a/gfx/gl/GLContext.cpp
+++ b/gfx/gl/GLContext.cpp
@@ -548,21 +548,18 @@ GLContext::InitWithPrefixImpl(const char
uint32_t majorVer, minorVer;
if (!ParseVersion(versionStr, &majorVer, &minorVer)) {
MOZ_ASSERT(false, "Failed to parse GL_VERSION");
return false;
}
MOZ_ASSERT(majorVer < 10);
MOZ_ASSERT(minorVer < 10);
mVersion = majorVer*100 + minorVer*10;
- if (mVersion < 200) {
- // Mac OSX 10.6/10.7 machines with Intel GPUs claim only OpenGL 1.4 but
- // have all the GL2+ extensions that we need.
- mVersion = 200;
- }
+ if (mVersion < 200)
+ return false;
////
const auto glslVersionStr = (const char*)fGetString(LOCAL_GL_SHADING_LANGUAGE_VERSION);
if (!glslVersionStr) {
// This happens on the Android emulators. We'll just return 100
mShadingLanguageVersion = 100;
} else if (ParseVersion(glslVersionStr, &majorVer, &minorVer)) {