mirror of
https://github.com/BinomialLLC/basis_universal.git
synced 2026-06-08 08:33:53 +00:00
Disallow all-zero-length Huffman tables
This commit is contained in:
@@ -160,7 +160,7 @@ namespace basist
|
||||
next_code[i + 1] = (total = ((total + syms_using_codesize[i]) << 1));
|
||||
}
|
||||
|
||||
if (((1U << basisu::cHuffmanMaxSupportedInternalCodeSize) != total) && (used_syms > 1U))
|
||||
if (((1U << basisu::cHuffmanMaxSupportedInternalCodeSize) != total) && (used_syms != 1U))
|
||||
return false;
|
||||
|
||||
for (int tree_next = -1, sym_index = 0; sym_index < (int)total_syms; ++sym_index)
|
||||
|
||||
Reference in New Issue
Block a user