mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-02 12:30:31 +00:00
AK: Account for bit position 8 in bit stream alignment
See identical code in LittleEndianBitStream; even in the bytewise reading BigEndianBitStream an offset of 8 is not inconsistent state and handled just fine by read_bits.
This commit is contained in:
parent
70c977aa56
commit
c9f6605fb2
Notes:
sideshowbarker
2024-07-16 20:51:53 +09:00
Author: https://github.com/kleinesfilmroellchen Commit: https://github.com/SerenityOS/serenity/commit/c9f6605fb2 Pull-request: https://github.com/SerenityOS/serenity/pull/18905 Reviewed-by: https://github.com/gmta ✅
1 changed files with 1 additions and 1 deletions
|
@ -109,7 +109,7 @@ public:
|
|||
}
|
||||
|
||||
/// Whether we are (accidentally or intentionally) at a byte boundary right now.
|
||||
ALWAYS_INLINE bool is_aligned_to_byte_boundary() const { return m_bit_offset == 0; }
|
||||
ALWAYS_INLINE bool is_aligned_to_byte_boundary() const { return m_bit_offset % 8 == 0; }
|
||||
|
||||
private:
|
||||
Optional<u8> m_current_byte;
|
||||
|
|
Loading…
Reference in a new issue