@@ -360,16 +360,14 @@ static void add_level(VLC_MULTI_ELEM *table, const int is16bit,
{
int max_symbols = VLC_MULTI_MAX_SYMBOLS >> is16bit;
for (int i = num-1; i >= max; i--) {
- for (int j = 0; j < 2; j++) {
int newlimit, sym;
- int t = j ? i-1 : i;
- int l = buf[t].bits;
+ int l = buf[i].bits;
uint32_t code;
- sym = buf[t].symbol;
+ sym = buf[i].symbol;
if (l >= curlimit)
return;
- code = curcode + (buf[t].code >> curlen);
+ code = curcode + (buf[i].code >> curlen);
newlimit = curlimit - l;
l += curlen;
if (is16bit) AV_WN16(info.val+2*curlevel, sym);
@@ -390,7 +388,6 @@ static void add_level(VLC_MULTI_ELEM *table, const int is16bit,
code, l, newlimit, curlevel+1,
minlen, max, levelcnt, info);
}
- }
}
}
No difference in my testcase in the tables content Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> --- libavcodec/vlc.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-)