mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-24 16:18:16 +00:00
audiodecoder: should post DECODE errors and not ENCODE
Fix error code for audio decoder
This commit is contained in:
parent
3f5b9c4c8b
commit
a0b25a570a
1 changed files with 3 additions and 3 deletions
|
@ -1172,7 +1172,7 @@ gst_audio_decoder_finish_frame (GstAudioDecoder * dec, GstBuffer * buf,
|
||||||
/* frame and ts book-keeping */
|
/* frame and ts book-keeping */
|
||||||
if (G_UNLIKELY (frames < 0)) {
|
if (G_UNLIKELY (frames < 0)) {
|
||||||
if (G_UNLIKELY (-frames - 1 > priv->frames.length)) {
|
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,
|
("received more decoded frames %d than provided %d", frames,
|
||||||
priv->frames.length), (NULL));
|
priv->frames.length), (NULL));
|
||||||
frames = 0;
|
frames = 0;
|
||||||
|
@ -1181,7 +1181,7 @@ gst_audio_decoder_finish_frame (GstAudioDecoder * dec, GstBuffer * buf,
|
||||||
}
|
}
|
||||||
} else if (G_UNLIKELY (frames > priv->frames.length)) {
|
} else if (G_UNLIKELY (frames > priv->frames.length)) {
|
||||||
if (G_LIKELY (!priv->force)) {
|
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,
|
("received more decoded frames %d than provided %d", frames,
|
||||||
priv->frames.length), (NULL));
|
priv->frames.length), (NULL));
|
||||||
}
|
}
|
||||||
|
@ -1287,7 +1287,7 @@ exit:
|
||||||
/* ERRORS */
|
/* ERRORS */
|
||||||
wrong_buffer:
|
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,
|
("buffer size %" G_GSIZE_FORMAT " not a multiple of %d", size,
|
||||||
ctx->info.bpf));
|
ctx->info.bpf));
|
||||||
gst_buffer_unref (buf);
|
gst_buffer_unref (buf);
|
||||||
|
|
Loading…
Reference in a new issue