Commit 32d508e2 by Geoff Lang

Fix checking for a NULL pointer after using the pointer.

Change-Id: I0ead14916ec677c97afb53f4c31a903e71fbc70f Reviewed-on: https://chromium-review.googlesource.com/185862Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Tested-by: 's avatarGeoff Lang <geofflang@chromium.org>
parent 2a20562f
......@@ -10183,16 +10183,14 @@ bool __stdcall glBindTexImage(egl::Surface *surface)
if (context)
{
gl::Texture2D *textureObject = context->getTexture2D();
ASSERT(textureObject != NULL);
if (textureObject->isImmutable())
{
return false;
}
if (textureObject)
{
textureObject->bindTexImage(surface);
}
textureObject->bindTexImage(surface);
}
}
catch(std::bad_alloc&)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment