[FFmpeg-cvslog] r19989 - trunk/libavcodec/vorbis_dec.c
michael
subversion
Wed Sep 23 14:02:32 CEST 2009
Author: michael
Date: Wed Sep 23 14:02:31 2009
New Revision: 19989
Log:
Check classbook value.
11_vorbis_residue_book_index.patch by chrome.
Modified:
trunk/libavcodec/vorbis_dec.c
Modified: trunk/libavcodec/vorbis_dec.c
==============================================================================
--- trunk/libavcodec/vorbis_dec.c Wed Sep 23 13:44:30 2009 (r19988)
+++ trunk/libavcodec/vorbis_dec.c Wed Sep 23 14:02:31 2009 (r19989)
@@ -630,6 +630,10 @@ static int vorbis_parse_setup_hdr_residu
res_setup->partition_size=get_bits(gb, 24)+1;
res_setup->classifications=get_bits(gb, 6)+1;
res_setup->classbook=get_bits(gb, 8);
+ if (res_setup->classbook>=vc->codebook_count) {
+ av_log(vc->avccontext, AV_LOG_ERROR, "classbook value %d out of range. \n", res_setup->classbook);
+ return 1;
+ }
AV_DEBUG(" begin %d end %d part.size %d classif.s %d classbook %d \n", res_setup->begin, res_setup->end, res_setup->partition_size,
res_setup->classifications, res_setup->classbook);
More information about the ffmpeg-cvslog
mailing list