diff options
Diffstat (limited to 'gst-libs')
-rw-r--r-- | gst-libs/gst/vaapi/gstvaapidecoder_h264.c | 12 | ||||
-rw-r--r-- | gst-libs/gst/vaapi/gstvaapidecoder_h265.c | 4 |
2 files changed, 8 insertions, 8 deletions
diff --git a/gst-libs/gst/vaapi/gstvaapidecoder_h264.c b/gst-libs/gst/vaapi/gstvaapidecoder_h264.c index fbff9bc7..d4bd6dda 100644 --- a/gst-libs/gst/vaapi/gstvaapidecoder_h264.c +++ b/gst-libs/gst/vaapi/gstvaapidecoder_h264.c @@ -769,7 +769,7 @@ dpb_find_nearest_prev_poc (GstVaapiDecoderH264 * decoder, { GstVaapiDecoderH264Private *const priv = &decoder->priv; GstVaapiPictureH264 *found_picture = NULL; - guint i, j, found_index; + guint i, j, found_index = -1; g_return_val_if_fail (picture != NULL, -1); @@ -793,7 +793,7 @@ dpb_find_nearest_prev_poc (GstVaapiDecoderH264 * decoder, if (found_picture_ptr) *found_picture_ptr = found_picture; - return found_picture ? found_index : -1; + return found_index; } /* Finds the picture with the lowest POC that needs to be output */ @@ -803,7 +803,7 @@ dpb_find_lowest_poc (GstVaapiDecoderH264 * decoder, { GstVaapiDecoderH264Private *const priv = &decoder->priv; GstVaapiPictureH264 *found_picture = NULL; - guint i, j, found_index; + guint i, j, found_index = -1; for (i = 0; i < priv->dpb_count; i++) { GstVaapiFrameStore *const fs = priv->dpb[i]; @@ -824,7 +824,7 @@ dpb_find_lowest_poc (GstVaapiDecoderH264 * decoder, if (found_picture_ptr) *found_picture_ptr = found_picture; - return found_picture ? found_index : -1; + return found_index; } /* Finds the picture with the lowest VOC that needs to be output */ @@ -834,7 +834,7 @@ dpb_find_lowest_voc (GstVaapiDecoderH264 * decoder, { GstVaapiDecoderH264Private *const priv = &decoder->priv; GstVaapiPictureH264 *found_picture = NULL; - guint i, j, found_index; + guint i, j, found_index = -1; for (i = 0; i < priv->dpb_count; i++) { GstVaapiFrameStore *const fs = priv->dpb[i]; @@ -851,7 +851,7 @@ dpb_find_lowest_voc (GstVaapiDecoderH264 * decoder, if (found_picture_ptr) *found_picture_ptr = found_picture; - return found_picture ? found_index : -1; + return found_index; } static gboolean diff --git a/gst-libs/gst/vaapi/gstvaapidecoder_h265.c b/gst-libs/gst/vaapi/gstvaapidecoder_h265.c index 6147e0c8..2675f79a 100644 --- a/gst-libs/gst/vaapi/gstvaapidecoder_h265.c +++ b/gst-libs/gst/vaapi/gstvaapidecoder_h265.c @@ -711,7 +711,7 @@ dpb_find_lowest_poc (GstVaapiDecoderH265 * decoder, { GstVaapiDecoderH265Private *const priv = &decoder->priv; GstVaapiPictureH265 *found_picture = NULL; - guint i, found_index; + guint i, found_index = -1; for (i = 0; i < priv->dpb_count; i++) { GstVaapiPictureH265 *const picture = priv->dpb[i]->buffer; @@ -723,7 +723,7 @@ dpb_find_lowest_poc (GstVaapiDecoderH265 * decoder, if (found_picture_ptr) *found_picture_ptr = found_picture; - return found_picture ? found_index : -1; + return found_index; } static gboolean |