diff options
-rw-r--r-- | ui/gl/gl_surface_egl.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ui/gl/gl_surface_egl.cc b/ui/gl/gl_surface_egl.cc index b35806d..17ecce7 100644 --- a/ui/gl/gl_surface_egl.cc +++ b/ui/gl/gl_surface_egl.cc @@ -374,6 +374,12 @@ bool PbufferGLSurfaceEGL::Initialize() { return false; } + if (size_.GetArea() == 0) { + LOG(ERROR) << "Error: surface has zero area " + << size_.width() << " x " << size_.height(); + return false; + } + const EGLint pbuffer_attribs[] = { EGL_WIDTH, size_.width(), EGL_HEIGHT, size_.height(), |