egl: Fix crashes in eglCreate*Surface()
authorChad Versace <chadversary@chromium.org>
Tue, 13 Dec 2016 22:23:55 +0000 (14:23 -0800)
committerChad Versace <chadversary@chromium.org>
Wed, 14 Dec 2016 20:03:15 +0000 (12:03 -0800)
commit5e97b8f5ce975dfb66cc46e6b4cc1e89eb8c1dc0
tree915e3f0fa039d394dbb7862449974ad08600aeeb
parentb18cd8ce2c07c2d1a666fbff1f0d92d17dd5b22c
egl: Fix crashes in eglCreate*Surface()

Don't dereference a null EGLDisplay.

Fixes tests
  dEQP-EGL.functional.negative_api.create_pbuffer_surface
  dEQP-EGL.functional.negative_api.create_pixmap_surface

Reviewed-by: Mark Janes <mark.a.janes@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=99038
Cc: "13.0" <mesa-stable@lists.freedesktop.org>
src/egl/main/eglapi.c