Commit b8002a0e authored by Thorvald Natvig's avatar Thorvald Natvig Committed by Jean-Marc Valin
Browse files

Varlength arrays fix for C89

parent e14fe904
......@@ -106,7 +106,9 @@ void _celt_autocorr(
{
float d;
int i;
float xx[n];
VARDECL(float, xx);
SAVE_STACK;
ALLOC(xx, n, float);
for (i=0;i<n;i++)
xx[i] = x[i];
for (i=0;i<overlap;i++)
......@@ -122,4 +124,5 @@ void _celt_autocorr(
lag--;
}
ac[0] += 10;
RESTORE_STACK;
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment