From f197749343676f31b47c0b6dba4e426609c5e74d Mon Sep 17 00:00:00 2001 From: Víctor Manuel Jáquez Leal Date: Tue, 8 Aug 2017 16:50:39 +0200 Subject: libs: encoder: h264: fix copy & paste error Coverity scan bug: The copied code will not have its intended effect. This is a bug from commit cdaf15b2, where the intention is to initialize RefPicList1 while setting RefPicList0. --- gst-libs/gst/vaapi/gstvaapiencoder_h264.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gst-libs/gst/vaapi/gstvaapiencoder_h264.c b/gst-libs/gst/vaapi/gstvaapiencoder_h264.c index 1a14f6c3..dab3c149 100644 --- a/gst-libs/gst/vaapi/gstvaapiencoder_h264.c +++ b/gst-libs/gst/vaapi/gstvaapiencoder_h264.c @@ -2128,7 +2128,7 @@ add_slice_headers (GstVaapiEncoderH264 * encoder, GstVaapiEncPicture * picture, } for (; i_ref < G_N_ELEMENTS (slice_param->RefPicList1); ++i_ref) { slice_param->RefPicList1[i_ref].picture_id = VA_INVALID_SURFACE; - slice_param->RefPicList0[i_ref].flags = VA_PICTURE_H264_INVALID; + slice_param->RefPicList1[i_ref].flags = VA_PICTURE_H264_INVALID; } /* not used if pic_param.pic_fields.bits.weighted_pred_flag == FALSE */ -- cgit v1.2.3