summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--gpu/command_buffer/service/context_group.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/gpu/command_buffer/service/context_group.cc b/gpu/command_buffer/service/context_group.cc
index 8437c66..4e625c41 100644
--- a/gpu/command_buffer/service/context_group.cc
+++ b/gpu/command_buffer/service/context_group.cc
@@ -137,12 +137,14 @@ bool ContextGroup::Initialize() {
// Lookup GL things we need to know.
GetIntegerv(GL_MAX_VERTEX_ATTRIBS, &max_vertex_attribs_);
- const GLuint kGLES2RequiredMiniumumVertexAttribs = 8u;
- DCHECK_GE(max_vertex_attribs_, kGLES2RequiredMiniumumVertexAttribs);
+ const GLuint kGLES2RequiredMinimumVertexAttribs = 8u;
+ if (max_vertex_attribs_ < kGLES2RequiredMinimumVertexAttribs)
+ return false;
GetIntegerv(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS, &max_texture_units_);
- const GLuint kGLES2RequiredMiniumumTextureUnits = 8u;
- DCHECK_GE(max_texture_units_, kGLES2RequiredMiniumumTextureUnits);
+ const GLuint kGLES2RequiredMinimumTextureUnits = 8u;
+ if (max_texture_units_ < kGLES2RequiredMinimumTextureUnits)
+ return false;
GLint max_texture_size;
GLint max_cube_map_texture_size;