1
0
Fork 0

Merging upstream version 1.0.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-17 18:44:28 +01:00
parent d24d609a01
commit a2dab4fd78
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
10 changed files with 48 additions and 39 deletions

View file

@ -43,7 +43,7 @@ static inline void Rd_init( struct Range_decoder * const rdec, const int infd )
rdec->pos = 0;
rdec->stream_pos = 0;
rdec->code = 0;
rdec->range = 0xFFFFFFFF;
rdec->range = 0xFFFFFFFFU;
rdec->infd_ = infd;
rdec->at_stream_end = false;
}
@ -242,7 +242,7 @@ static inline uint8_t Lid_decode_matched( struct Literal_decoder * const literal
struct LZ_decoder
{
long long partial_data_pos;
int format_version;
int member_version;
int dictionary_size;
int buffer_size;
uint8_t * buffer;
@ -313,7 +313,7 @@ static inline void LZd_init( struct LZ_decoder * const decoder,
struct Range_decoder * const rdec, const int outfd )
{
decoder->partial_data_pos = 0;
decoder->format_version = Fh_version( header );
decoder->member_version = Fh_version( header );
decoder->dictionary_size = Fh_get_dictionary_size( header );
decoder->buffer_size = max( 65536, decoder->dictionary_size );
decoder->buffer = (uint8_t *)malloc( decoder->buffer_size );