<div dir="ltr"><div>Thx for the patch:<br>Reviewed-by: Julien Isorce <<a href="mailto:j.isorce@samsung.com" target="_blank">j.isorce@samsung.com</a>><br><br></div>I'll push it today.</div><div class="gmail_extra"><br><div class="gmail_quote">On 26 June 2016 at 08:02, Gurkirpal Singh <span dir="ltr"><<a href="mailto:gurkirpal204@gmail.com" target="_blank">gurkirpal204@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Call to handle_table_get in vlVaDestroySurfaces can<br>
return NULL on failure.<br>
<br>
CID: 1243522<br>
<br>
Signed-off-by: Gurkirpal Singh <<a href="mailto:gurkirpal204@gmail.com">gurkirpal204@gmail.com</a>><br>
---<br>
src/gallium/state_trackers/va/surface.c | 4 ++++<br>
1 file changed, 4 insertions(+)<br>
<br>
diff --git a/src/gallium/state_trackers/va/surface.c b/src/gallium/state_trackers/va/surface.c<br>
index 5efb893..3e74353 100644<br>
--- a/src/gallium/state_trackers/va/surface.c<br>
+++ b/src/gallium/state_trackers/va/surface.c<br>
@@ -71,6 +71,10 @@ vlVaDestroySurfaces(VADriverContextP ctx, VASurfaceID *surface_list, int num_sur<br>
pipe_mutex_lock(drv->mutex);<br>
for (i = 0; i < num_surfaces; ++i) {<br>
vlVaSurface *surf = handle_table_get(drv->htab, surface_list[i]);<br>
+ if (!surf) {<br>
+ pipe_mutex_unlock(drv->mutex);<br>
+ return VA_STATUS_ERROR_INVALID_SURFACE;<br>
+ }<br>
if (surf->buffer)<br>
surf->buffer->destroy(surf->buffer);<br>
util_dynarray_fini(&surf->subpics);<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.7.4<br>
<br>
_______________________________________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div>