mirror of
https://codeberg.org/icewind/bitbuffer.git
synced 2026-06-03 16:44:06 +02:00
fix skip_bits check when skipping to the end of the stream
This commit is contained in:
parent
894c8aef7c
commit
aa42c955ce
1 changed files with 1 additions and 1 deletions
|
|
@ -405,7 +405,7 @@ where
|
|||
///
|
||||
/// [`ReadError::NotEnoughData`]: enum.ReadError.html#variant.NotEnoughData
|
||||
pub fn skip_bits(&mut self, count: usize) -> Result<()> {
|
||||
if count < self.bits_left() {
|
||||
if count <= self.bits_left() {
|
||||
self.pos += count;
|
||||
Ok(())
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue