diff options
Diffstat (limited to 'brotli/dec/bit_reader.c')
-rw-r--r-- | brotli/dec/bit_reader.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/brotli/dec/bit_reader.c b/brotli/dec/bit_reader.c index 25e33e3..981dccf 100644 --- a/brotli/dec/bit_reader.c +++ b/brotli/dec/bit_reader.c @@ -33,7 +33,7 @@ int BrotliInitBitReader(BrotliBitReader* const br, BrotliInput input) { br->val_ = 0; br->pos_ = 0; br->bit_pos_ = 0; - br->bits_left_ = 64; + br->bit_end_pos_ = 0; br->eos_ = 0; if (!BrotliReadMoreInput(br)) { return 0; @@ -42,7 +42,7 @@ int BrotliInitBitReader(BrotliBitReader* const br, BrotliInput input) { br->val_ |= ((uint64_t)br->buf_[br->pos_]) << (8 * i); ++br->pos_; } - return (br->bits_left_ > 64); + return (br->bit_end_pos_ > 0); } #if defined(__cplusplus) || defined(c_plusplus) |