diff options
-rw-r--r-- | Userland/Libraries/LibCompress/Lzma.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Userland/Libraries/LibCompress/Lzma.cpp b/Userland/Libraries/LibCompress/Lzma.cpp index f5b8751f98..e1dc18c847 100644 --- a/Userland/Libraries/LibCompress/Lzma.cpp +++ b/Userland/Libraries/LibCompress/Lzma.cpp @@ -284,6 +284,8 @@ ErrorOr<void> LzmaCompressor::normalize_range_encoder() ErrorOr<u8> LzmaDecompressor::decode_direct_bit() { + dbgln_if(LZMA_DEBUG, "Decoding direct bit {} with code = {:#x}, range = {:#x}", 1 - ((m_range_decoder_code - (m_range_decoder_range >> 1)) >> 31), m_range_decoder_code, m_range_decoder_range); + m_range_decoder_range >>= 1; m_range_decoder_code -= m_range_decoder_range; @@ -301,6 +303,8 @@ ErrorOr<u8> LzmaDecompressor::decode_direct_bit() ErrorOr<void> LzmaCompressor::encode_direct_bit(u8 value) { + dbgln_if(LZMA_DEBUG, "Encoding direct bit {} with code = {:#x}, range = {:#x}", value, m_range_encoder_code, m_range_encoder_range); + m_range_encoder_range >>= 1; if (value != 0) |