Module: Mesa Branch: master Commit: 3cdb548bfbc77522ed4e956f7457c8339182ff8c URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=3cdb548bfbc77522ed4e956f7457c8339182ff8c
Author: Tapani Pälli <tapani.pa...@intel.com> Date: Wed Feb 20 13:00:08 2013 +0200 mesa/es: NULL check in EGLImageTargetTexture2DOES check that pointer passed is valid and return error if not. Note: This is a candidate for the stable branches. Signed-off-by: Tapani Pälli <tapani.pa...@intel.com> Reviewed-by: Ian Romanick <ian.d.roman...@intel.com> Reviewed-by: Chad Versace <chad.vers...@linux.intel.com> --- src/mesa/main/teximage.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index f8f517a..f0de0fb 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -3187,6 +3187,12 @@ _mesa_EGLImageTargetTexture2DOES (GLenum target, GLeglImageOES image) return; } + if (!image) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "glEGLImageTargetTexture2D(image=%p)", image); + return; + } + if (ctx->NewState & _NEW_PIXEL) _mesa_update_state(ctx); _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-commit