aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>2008-04-26 14:41:29 +0000
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>2008-04-26 14:41:29 +0000
commit169203c1d9999aee58bd756b2acf386115e34856 (patch)
tree271db62241dbff0a67c9fa561720716e6fe970c5 /libavcodec
parent41b8800f8861a6d7eac3a37ea39f5476abd73e92 (diff)
downloadffmpeg-169203c1d9999aee58bd756b2acf386115e34856.tar.gz
break if error in header so it can output already decoded frames
Originally committed as revision 12999 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/mpegaudiodec.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/libavcodec/mpegaudiodec.c b/libavcodec/mpegaudiodec.c
index 108b745527..9b22014c7c 100644
--- a/libavcodec/mpegaudiodec.c
+++ b/libavcodec/mpegaudiodec.c
@@ -2591,10 +2591,8 @@ static int decode_frame_mp3on4(AVCodecContext * avctx,
header = (AV_RB32(buf) & 0x000fffff) | s->syncword; // patch header
- if (ff_mpa_check_header(header) < 0) { // Bad header, discard block
- *data_size = 0;
- return buf_size;
- }
+ if (ff_mpa_check_header(header) < 0) // Bad header, discard block
+ break;
ff_mpegaudio_decode_header(m, header);
out_size += mp_decode_frame(m, outptr, buf, fsize);