From: "Timothy B. Terriberry" <tterribe@vt.edu>
Date: Fri, 20 Jan 2012 22:54:44 +1300
Subject: Bug 719612 - Update libvorbis. r=kinetik a=akeybl

---
 media/libvorbis/lib/vorbis_floor1.c |    1 +
 media/libvorbis/update.sh           |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/media/libvorbis/lib/vorbis_floor1.c b/media/libvorbis/lib/vorbis_floor1.c
index c031a23..8dce764 100644
--- a/media/libvorbis/lib/vorbis_floor1.c
+++ b/media/libvorbis/lib/vorbis_floor1.c
@@ -160,6 +160,7 @@ static vorbis_info_floor *floor1_unpack (vorbis_info *vi,oggpack_buffer *opb){
 
   for(j=0,k=0;j<info->partitions;j++){
     count+=info->class_dim[info->partitionclass[j]];
+    if(count>VIF_POSIT) goto err_out;
     for(;k<count;k++){
       int t=info->postlist[k+2]=oggpack_read(opb,rangebits);
       if(t<0 || t>=(1<<rangebits))
diff --git a/media/libvorbis/update.sh b/media/libvorbis/update.sh
index 51d07a9..3a12f02 100644
--- a/media/libvorbis/update.sh
+++ b/media/libvorbis/update.sh
@@ -47,6 +47,7 @@ cp $1/COPYING ./COPYING
 cp $1/README ./README
 cp $1/AUTHORS ./AUTHORS
 patch -p3 < ./alloca.diff
+patch -p3 < ./bug719612.patch
 patch -p3 <./bug481601.patch
 patch -p3 <bug487519.patch
 patch -p3 <bug498855.patch
