diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/state_trackers/va/config.c | 4 | ||||
-rw-r--r-- | src/gallium/state_trackers/va/image.c | 4 | ||||
-rw-r--r-- | src/gallium/state_trackers/va/picture.c | 4 |
3 files changed, 9 insertions, 3 deletions
diff --git a/src/gallium/state_trackers/va/config.c b/src/gallium/state_trackers/va/config.c index 25043d63742..7bc031a1a2f 100644 --- a/src/gallium/state_trackers/va/config.c +++ b/src/gallium/state_trackers/va/config.c @@ -308,8 +308,10 @@ vlVaDestroyConfig(VADriverContextP ctx, VAConfigID config_id) mtx_lock(&drv->mutex); config = handle_table_get(drv->htab, config_id); - if (!config) + if (!config) { + mtx_unlock(&drv->mutex); return VA_STATUS_ERROR_INVALID_CONFIG; + } FREE(config); handle_table_remove(drv->htab, config_id); diff --git a/src/gallium/state_trackers/va/image.c b/src/gallium/state_trackers/va/image.c index 86ae8685802..3f892c9842c 100644 --- a/src/gallium/state_trackers/va/image.c +++ b/src/gallium/state_trackers/va/image.c @@ -548,8 +548,10 @@ vlVaPutImage(VADriverContextP ctx, VASurfaceID surface, VAImageID image, PIPE_TRANSFER_WRITE | PIPE_TRANSFER_DISCARD_RANGE, &dst_box, &transfer); - if (map == NULL) + if (map == NULL) { + mtx_unlock(&drv->mutex); return VA_STATUS_ERROR_OPERATION_FAILED; + } u_copy_nv12_from_yv12((const void * const*) data, pitches, i, j, transfer->stride, tex->array_size, diff --git a/src/gallium/state_trackers/va/picture.c b/src/gallium/state_trackers/va/picture.c index 23a4b524d7b..22934e43ccd 100644 --- a/src/gallium/state_trackers/va/picture.c +++ b/src/gallium/state_trackers/va/picture.c @@ -682,9 +682,11 @@ vlVaEndPicture(VADriverContextP ctx, VAContextID context_id) vl_compositor_yuv_deint_full(&drv->cstate, &drv->compositor, old_buf, surf->buffer, &src_rect, &dst_rect, VL_COMPOSITOR_WEAVE); - } else + } else { /* Can't convert from progressive to interlaced yet */ + mtx_unlock(&drv->mutex); return VA_STATUS_ERROR_INVALID_SURFACE; + } } old_buf->destroy(old_buf); |