From: Hans Kristian Rosbach Date: Tue, 5 May 2020 10:05:46 +0000 (+0200) Subject: Change two NOT_TWEAK_COMPILER to check for MIN-MATCH!=3 instead. X-Git-Tag: 1.9.9-b1~307 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=06173b6a49ae4a331758e009885e1aa1829cdd19;p=thirdparty%2Fzlib-ng.git Change two NOT_TWEAK_COMPILER to check for MIN-MATCH!=3 instead. --- diff --git a/deflate_fast.c b/deflate_fast.c index 1277b773a..4fdad4fdc 100644 --- a/deflate_fast.c +++ b/deflate_fast.c @@ -76,13 +76,10 @@ ZLIB_INTERNAL block_state deflate_fast(deflate_state *s, int flush) { s->strstart += s->match_length; s->match_length = 0; s->ins_h = s->window[s->strstart]; -#ifndef NOT_TWEAK_COMPILER +#if MIN_MATCH != 3 functable.insert_string(s, s->strstart + 2 - MIN_MATCH, MIN_MATCH - 2); #else functable.quick_insert_string(s, s->strstart + 2 - MIN_MATCH); -#if MIN_MATCH != 3 -#warning Call insert_string() MIN_MATCH-3 more times -#endif #endif /* If lookahead < MIN_MATCH, ins_h is garbage, but it does not * matter since it will be recomputed at next deflate call. diff --git a/deflate_medium.c b/deflate_medium.c index d5fbfe71b..3a13afbd7 100644 --- a/deflate_medium.c +++ b/deflate_medium.c @@ -88,13 +88,10 @@ static void insert_match(deflate_state *s, struct match match) { match.match_length = 0; s->ins_h = s->window[match.strstart]; if (match.strstart >= (MIN_MATCH - 2)) -#ifndef NOT_TWEAK_COMPILER +#if MIN_MATCH != 3 functable.insert_string(s, match.strstart + 2 - MIN_MATCH, MIN_MATCH - 2); #else functable.quick_insert_string(s, match.strstart + 2 - MIN_MATCH); -#if MIN_MATCH != 3 -#warning Call insert_string() MIN_MATCH-3 more times -#endif #endif /* If lookahead < MIN_MATCH, ins_h is garbage, but it does not * matter since it will be recomputed at next deflate call.