From a0b25a570aa470c520343fea4b70e5ac1cbc4519 Mon Sep 17 00:00:00 2001 From: Thiago Santos Date: Mon, 13 Oct 2014 22:24:31 -0300 Subject: [PATCH] audiodecoder: should post DECODE errors and not ENCODE Fix error code for audio decoder --- gst-libs/gst/audio/gstaudiodecoder.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gst-libs/gst/audio/gstaudiodecoder.c b/gst-libs/gst/audio/gstaudiodecoder.c index 4634249995..84b6242310 100644 --- a/gst-libs/gst/audio/gstaudiodecoder.c +++ b/gst-libs/gst/audio/gstaudiodecoder.c @@ -1172,7 +1172,7 @@ gst_audio_decoder_finish_frame (GstAudioDecoder * dec, GstBuffer * buf, /* frame and ts book-keeping */ if (G_UNLIKELY (frames < 0)) { if (G_UNLIKELY (-frames - 1 > priv->frames.length)) { - GST_ELEMENT_WARNING (dec, STREAM, ENCODE, + GST_ELEMENT_WARNING (dec, STREAM, DECODE, ("received more decoded frames %d than provided %d", frames, priv->frames.length), (NULL)); frames = 0; @@ -1181,7 +1181,7 @@ gst_audio_decoder_finish_frame (GstAudioDecoder * dec, GstBuffer * buf, } } else if (G_UNLIKELY (frames > priv->frames.length)) { if (G_LIKELY (!priv->force)) { - GST_ELEMENT_WARNING (dec, STREAM, ENCODE, + GST_ELEMENT_WARNING (dec, STREAM, DECODE, ("received more decoded frames %d than provided %d", frames, priv->frames.length), (NULL)); } @@ -1287,7 +1287,7 @@ exit: /* ERRORS */ wrong_buffer: { - GST_ELEMENT_ERROR (dec, STREAM, ENCODE, (NULL), + GST_ELEMENT_ERROR (dec, STREAM, DECODE, (NULL), ("buffer size %" G_GSIZE_FORMAT " not a multiple of %d", size, ctx->info.bpf)); gst_buffer_unref (buf);