From: Steinar H. Gunderson Date: Mon, 1 Jun 2009 16:07:47 +0000 (+0200) Subject: Fix some errors/warnings in driver.c. X-Git-Url: https://git.sesse.net/?p=fjl;a=commitdiff_plain;h=707b73cb6536bc977eaca6033a93a749c4d89b19 Fix some errors/warnings in driver.c. --- diff --git a/driver.c b/driver.c index c5ae87e..6dcc8b3 100644 --- a/driver.c +++ b/driver.c @@ -121,8 +121,6 @@ void decode_ac_coefficients(const struct huffman_table* tbl, struct bit_source* unsigned lookup = peek_bits(bits, DEHUF_AC_TABLE_BITS); int code = tbl->ac_table_codes[lookup]; - assert(length == AC_DEHUF_SLOW_PATH || (length > 0 && length <= DEHUF_AC_TABLE_BITS)); - if (__builtin_expect(code == AC_DEHUF_SLOW_PATH, 0)) { unsigned rs = read_huffman_symbol_no_refill(tbl, bits); unsigned r = rs >> 4; @@ -143,7 +141,7 @@ void decode_ac_coefficients(const struct huffman_table* tbl, struct bit_source* coeff[unzigzag[i]] = extend(read_bits(bits, s), s); } else { - int length = tbl->ac_table_length[lookup]; + unsigned length = tbl->ac_table_length[lookup]; int r = tbl->ac_table_skip[lookup]; assert(r >= 0); i += r;