Merging upstream version 1.7~rc1.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
cb8306f68b
commit
f559c459b4
17 changed files with 120 additions and 123 deletions
|
@ -338,14 +338,14 @@ struct LZ_decoder
|
|||
static inline bool LZd_enough_free_bytes( const struct LZ_decoder * const d )
|
||||
{ return Cb_free_bytes( &d->cb ) >= lzd_min_free_bytes; }
|
||||
|
||||
static inline uint8_t LZd_get_prev_byte( const struct LZ_decoder * const d )
|
||||
static inline uint8_t LZd_peek_prev( const struct LZ_decoder * const d )
|
||||
{
|
||||
const int i = ( ( d->cb.put > 0 ) ? d->cb.put : d->cb.buffer_size ) - 1;
|
||||
return d->cb.buffer[i];
|
||||
}
|
||||
|
||||
static inline uint8_t LZd_get_byte( const struct LZ_decoder * const d,
|
||||
const int distance )
|
||||
static inline uint8_t LZd_peek( const struct LZ_decoder * const d,
|
||||
const int distance )
|
||||
{
|
||||
int i = d->cb.put - distance - 1;
|
||||
if( i < 0 ) i += d->cb.buffer_size;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue