[FFmpeg-cvslog] mpegaudidec: 10l forgot buf_size

Michael Niedermayer git at videolan.org
Sat May 19 22:25:21 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat May 19 22:22:45 2012 +0200| [c5371f775ca13cee114eea2d17e59af5a436a125] | committer: Michael Niedermayer

mpegaudidec: 10l forgot buf_size

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c5371f775ca13cee114eea2d17e59af5a436a125
---

 libavcodec/mpegaudiodec.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/libavcodec/mpegaudiodec.c b/libavcodec/mpegaudiodec.c
index 8635d47..64cbba8 100644
--- a/libavcodec/mpegaudiodec.c
+++ b/libavcodec/mpegaudiodec.c
@@ -1637,8 +1637,10 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *got_frame_ptr,
     uint32_t header;
     int out_size;
 
-    while(buf_size && !*buf)
+    while(buf_size && !*buf){
         buf++;
+        buf_size--;
+    }
 
     if (buf_size < HEADER_SIZE)
         return AVERROR_INVALIDDATA;



More information about the ffmpeg-cvslog mailing list