Fixes:
4373dd32154 ("st/va: Support YUV formats in vaCreateSurfaces")
Cc: Drew Davenport <ddavenport@chromium.org>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
(cherry picked from commit
04298a2f24455541f28ccffd2f0f73b831833d57)
return VA_STATUS_SUCCESS;
fail:
- for (i = 0; i < VL_NUM_COMPONENTS; i++) {
- if (resources[i])
- pscreen->resource_destroy(pscreen, resources[i]);
- }
+ for (i = 0; i < VL_NUM_COMPONENTS; i++)
+ pipe_resource_reference(&resources[i], NULL);
return result;
}