[xiph-commits] r14604 - trunk/vorbis/lib
xiphmont at svn.xiph.org
xiphmont at svn.xiph.org
Wed Mar 19 01:03:29 PDT 2008
Author: xiphmont
Date: 2008-03-19 01:03:29 -0700 (Wed, 19 Mar 2008)
New Revision: 14604
Modified:
trunk/vorbis/lib/codebook.c
Log:
dd checks/rejection for absurdly huge codebooks.
Modified: trunk/vorbis/lib/codebook.c
===================================================================
--- trunk/vorbis/lib/codebook.c 2008-03-19 08:02:58 UTC (rev 14603)
+++ trunk/vorbis/lib/codebook.c 2008-03-19 08:03:29 UTC (rev 14604)
@@ -159,6 +159,8 @@
s->entries=oggpack_read(opb,24);
if(s->entries==-1)goto _eofout;
+ if(_ilog(s->dim)+_ilog(s->entries)>24)goto _eofout;
+
/* codeword ordering.... length ordered or unordered? */
switch((int)oggpack_read(opb,1)){
case 0:
More information about the commits
mailing list