mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-23 00:47:56 +01:00
Fix C decode_huffman's exit with excess high bits.
This commit is contained in:
1 parent
61c5b40bf6
commit
bc92bf4ff8
1 file changed
+1
@@ -223,6 +223,7 @@ end:
|
|||||||
for (; n_bits >= 8; n_bits -= 8) {
|
for (; n_bits >= 8; n_bits -= 8) {
|
||||||
psrc--;
|
psrc--;
|
||||||
}
|
}
|
||||||
|
bits &= (((uint32_t)(1)) << n_bits) - 1;
|
||||||
|
|
||||||
// Save contextual state.
|
// Save contextual state.
|
||||||
a_dst.buf->wi = pdst - a_dst.buf->ptr;
|
a_dst.buf->wi = pdst - a_dst.buf->ptr;
|
||||||
|
|||||||
Reference in new issue
Block a user