1
0
Fork 0

Merging upstream version 1.4~pre1.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-24 04:08:36 +01:00
parent 86231bd436
commit 4d00ad10a7
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
9 changed files with 99 additions and 75 deletions

View file

@ -375,8 +375,11 @@ extern "C" void * cworker( void * arg )
Packet * const packet = courier.distribute_packet();
if( !packet ) break; // no more packets to process
const int dict_size = std::max( LZ_min_dictionary_size(),
std::min( dictionary_size, packet->size ) );
int dict_size;
if( dictionary_size == 65535 && match_len_limit == 16 )
dict_size = dictionary_size;
else dict_size = std::max( LZ_min_dictionary_size(),
std::min( dictionary_size, packet->size ) );
LZ_Encoder * const encoder =
LZ_compress_open( dict_size, match_len_limit, LLONG_MAX );
if( !encoder || LZ_compress_errno( encoder ) != LZ_ok )