diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-10-21 01:31:53 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-10-21 02:52:10 +0200 |
commit | 7696a392e2d28efd1af6271f86b67b6ec4fa6408 (patch) | |
tree | 2842c55f29dd03545b4a3993fa154c865b5238fa | |
parent | 273fca9ac071da4078afa61f087e1e90fafd4958 (diff) | |
download | ffmpeg-7696a392e2d28efd1af6271f86b67b6ec4fa6408.tar.gz |
mp3dec: propagate error code correctly.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/mpegaudiodec.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/mpegaudiodec.c b/libavcodec/mpegaudiodec.c index 6ef1f6b427..77f86c5549 100644 --- a/libavcodec/mpegaudiodec.c +++ b/libavcodec/mpegaudiodec.c @@ -1616,6 +1616,9 @@ static int mp_decode_frame(MPADecodeContext *s, OUT_INT *samples, s->last_buf_size += i; } + if(nb_frames < 0) + return nb_frames; + /* get output buffer */ if (!samples) { s->frame.nb_samples = s->avctx->frame_size; |