ref: 18c1c22e160a3f5f6073d276c006301355fa6aee
parent: aa9362564d27daf54e43539f5f5e4d8c2e4401ea
author: Jean-Marc Valin <[email protected]>
date: Sat May 30 05:50:47 EDT 2009
Fix for a mode memory leak -- was still allocating memory for the energy allocator which was removed a while ago.
--- a/libcelt/modes.c
+++ b/libcelt/modes.c
@@ -207,7 +207,7 @@
static void compute_allocation_table(CELTMode *mode, int res)
{
int i, j, nBark;
- celt_int16_t *allocVectors, *allocEnergy;
+ celt_int16_t *allocVectors;
const int C = CHANNELS(mode);
/* Find the number of critical bands supported by our sampling rate */
@@ -217,7 +217,6 @@
mode->nbAllocVectors = BITALLOC_SIZE;
allocVectors = celt_alloc(sizeof(celt_int16_t)*(BITALLOC_SIZE*mode->nbEBands));
- allocEnergy = celt_alloc(sizeof(celt_int16_t)*(mode->nbAllocVectors*(mode->nbEBands+1)));
/* Compute per-codec-band allocation from per-critical-band matrix */
for (i=0;i<BITALLOC_SIZE;i++)
{