mpegaudio_parser: reset state to prevent it to be random
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 14 Sep 2012 03:55:11 +0000 (05:55 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 14 Sep 2012 03:55:11 +0000 (05:55 +0200)
Fixes Ticket1718

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/mpegaudio_parser.c

index afa2975..5f97d71 100644 (file)
@@ -54,6 +54,7 @@ static int mpegaudio_parse(AVCodecParserContext *s1,
             int inc= FFMIN(buf_size - i, s->frame_size);
             i += inc;
             s->frame_size -= inc;
+            state = 0;
 
             if(!s->frame_size){
                 next= i;