Y and UV planes release mechanism fix

The Y and UV planes weren't getting released properly because the local
variables used in base::RetainBlock() are snapshots of their current
values and do not get updated by subsequent code. In this case,
y_surface and uv_surface would always be at their original value of
EGL_NO_SURFACE and eglReleaseTexImage/eglDestroySurface would never get
called. Using pointers to these values solves the issue, since the
pointers do not get modified by subsequent code and the values can be
checked properly by dereferencing the pointers.

Bug: chromium:932986 chromium:929088
Change-Id: Id0b9fcc79af733b645eaf8fed12d905dd40e9fbc
Reviewed-on: https://chromium-review.googlesource.com/c/1483690
Reviewed-by: Antoine Labour <piman@chromium.org>
Reviewed-by: Kenneth Russell <kbr@chromium.org>
Commit-Queue: Alexis Hétu <sugoi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#634837}
1 file changed