Fix for layouts of 22 band and more
authorJean-Marc Valin <jean-marc.valin@usherbrooke.ca>
Sat, 12 Feb 2011 02:56:11 +0000 (21:56 -0500)
committerJean-Marc Valin <jean-marc.valin@usherbrooke.ca>
Sat, 12 Feb 2011 02:56:45 +0000 (21:56 -0500)
libcelt/modes.c

index 4d39417..7649143 100644 (file)
@@ -214,7 +214,7 @@ static void compute_allocation_table(CELTMode *mode)
             if (400*(celt_int32)eband5ms[k] > mode->eBands[j]*(celt_int32)mode->Fs/mode->shortMdctSize)
                break;
          }
-         if (k>mode->nbEBands-1)
+         if (k>maxBands-1)
             allocVectors[i*mode->nbEBands+j] = band_allocation[i*maxBands + maxBands-1];
          else {
             celt_int32 a0, a1;