avauddec: If decoding a frame failed, skip it

Otherwise the next successfully decoded frame will get its timestamp and we
will slowly let a/v sync drift apart.

https://bugzilla.gnome.org/show_bug.cgi?id=765797
This commit is contained in:
Sebastian Dröge 2016-04-29 12:55:19 +03:00
parent 151cd32a10
commit 00ebf95e08

View file

@ -819,6 +819,9 @@ gst_ffmpegauddec_handle_frame (GstAudioDecoder * decoder, GstBuffer * inbuf)
ret = ret =
gst_audio_decoder_finish_frame (GST_AUDIO_DECODER (ffmpegdec), gst_audio_decoder_finish_frame (GST_AUDIO_DECODER (ffmpegdec),
ffmpegdec->outbuf, 1); ffmpegdec->outbuf, 1);
else if (len < 0)
ret =
gst_audio_decoder_finish_frame (GST_AUDIO_DECODER (ffmpegdec), NULL, 1);
ffmpegdec->outbuf = NULL; ffmpegdec->outbuf = NULL;
if (bsize > 0) { if (bsize > 0) {