[Libva] [PATCH v3][libva-intel-driver] i965_encoder: remove double check for VAStatus result

Sean V Kelley seanvk at posteo.de
Thu Aug 18 20:03:00 UTC 2016


On Thu, 2016-08-18 at 12:43 -0700, Daniel Charles wrote:
> after creating underlying surface there's a double check on the
> VAStatus result. Replace it with ASSERT_RET.
> 
> Signed-off-by: Daniel Charles <daniel.charles at intel.com>

lgtm, applied.

Thanks,

Sean

> ---
>  src/i965_encoder.c | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)
> 
> diff --git a/src/i965_encoder.c b/src/i965_encoder.c
> index beea811..47368fb 100644
> --- a/src/i965_encoder.c
> +++ b/src/i965_encoder.c
> @@ -153,10 +153,7 @@ intel_encoder_check_yuv_surface(VADriverContextP
> ctx,
>                                   VA_RT_FORMAT_YUV420,
>                                   1,
>                                   &encoder_context-
> >input_yuv_surface);
> -    assert(status == VA_STATUS_SUCCESS);
> -
> -    if (status != VA_STATUS_SUCCESS)
> -        return status;
> +    ASSERT_RET(status == VA_STATUS_SUCCESS, status);
>  
>      obj_surface = SURFACE(encoder_context->input_yuv_surface);
>      encode_state->input_yuv_object = obj_surface;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/libva/attachments/20160818/b80d1310/attachment.sig>


More information about the Libva mailing list