mirror of
https://github.com/collinsmith/riiablo.git
synced 2025-07-10 07:47:42 +07:00
Fixed issue where flush would write more bits than cached
This commit is contained in:
@ -58,7 +58,7 @@ public class BitOutput {
|
||||
assert bitsCached >= 0 : "bitsCached(" + bitsCached + ") < " + 0;
|
||||
assert bitsCached < Byte.SIZE : "bitsCached(" + bitsCached + ") > " + (Byte.SIZE - 1);
|
||||
if (bitsCached <= 0) return this;
|
||||
byteOutput._write8(cache);
|
||||
byteOutput._write8(cache & MASKS[bitsCached]);
|
||||
clearCache();
|
||||
return this;
|
||||
}
|
||||
|
Reference in New Issue
Block a user