diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2005-02-04 11:53:35 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2005-02-04 11:53:35 +0000 |
commit | db2fcbbdb383a1a6d024a3884095269fa7eefd36 (patch) | |
tree | 2baad06a734bc9a6a8502484d17a0d192f6e6201 | |
parent | 8d65750ef1089561f0257fa1719b3094f341d16f (diff) | |
download | ffmpeg-db2fcbbdb383a1a6d024a3884095269fa7eefd36.tar.gz |
10l (use of deallocated memory)
Originally committed as revision 3936 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/flac.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/libavcodec/flac.c b/libavcodec/flac.c index 3de62bed2f..c308133cd6 100644 --- a/libavcodec/flac.c +++ b/libavcodec/flac.c @@ -634,10 +634,16 @@ static int flac_decode_frame(AVCodecContext *avctx, if(metadata_size){ switch(metadata_type) { - case METADATA_TYPE_STREAMINFO: + case METADATA_TYPE_STREAMINFO:{ + int bits_count= get_bits_count(&s->gb); + metadata_streaminfo(s); + buf= &s->bitstream[s->bitstream_index]; + init_get_bits(&s->gb, buf, buf_size*8); + skip_bits(&s->gb, bits_count); + dump_headers(s); - break; + break;} default: for(i=0; i<metadata_size; i++) skip_bits(&s->gb, 8); |