vaapidecode: unref video codec frame twice
authorMichael Olbrich <m.olbrich@pengutronix.de>
Thu, 11 Dec 2014 11:02:38 +0000 (12:02 +0100)
committerVíctor Manuel Jáquez Leal <vjaquez@igalia.com>
Fri, 10 Apr 2015 10:42:38 +0000 (12:42 +0200)
commita314b682b2520415a62c474611ea514308336fa5
tree44c92b1d737fda7b653937e558d0522b6b6342ac
parent93d0141cc296e9ff8a0fc2994940380a95f56eb7
vaapidecode: unref video codec frame twice

We get one reference when the frame is passed to decode_handle_frame()
and create another one in gst_vaapi_decoder_push_frame().

Usually the frame is handled in gst_vaapidecode_push_decoded_frame().
Here the frame is always released twice:
gst_video_decoder_finish_frame() + gst_video_codec_frame_unref() or
gst_video_decoder_drop_frame() + gst_video_codec_frame_unref().

In gst_vaapidecode_reset_full() both references to the frame must be
released as well.

Signed-off-by: Víctor Manuel Jáquez Leal <vjaquez@igalia.com>
https://bugzilla.gnome.org/show_bug.cgi?id=743226
gst/vaapi/gstvaapidecode.c