[FFmpeg-cvslog] mpegaudiodec: skip initial zeros.
Michael Niedermayer
git at videolan.org
Sat May 19 22:22:22 CEST 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat May 19 22:15:21 2012 +0200| [43bc5cf9f457c3a7caabc3781a71dee8dd4086ee] | committer: Michael Niedermayer
mpegaudiodec: skip initial zeros.
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=43bc5cf9f457c3a7caabc3781a71dee8dd4086ee
---
libavcodec/mpegaudiodec.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/libavcodec/mpegaudiodec.c b/libavcodec/mpegaudiodec.c
index 6a2b0fd..8635d47 100644
--- a/libavcodec/mpegaudiodec.c
+++ b/libavcodec/mpegaudiodec.c
@@ -1637,6 +1637,9 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *got_frame_ptr,
uint32_t header;
int out_size;
+ while(buf_size && !*buf)
+ buf++;
+
if (buf_size < HEADER_SIZE)
return AVERROR_INVALIDDATA;
More information about the ffmpeg-cvslog
mailing list