]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
Change two NOT_TWEAK_COMPILER to check for MIN-MATCH!=3 instead.
authorHans Kristian Rosbach <hk-git@circlestorm.org>
Tue, 5 May 2020 10:05:46 +0000 (12:05 +0200)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Wed, 6 May 2020 08:00:11 +0000 (10:00 +0200)
deflate_fast.c
deflate_medium.c

index 1277b773a53b86dfe51b1454c84fc2926c4a1ed9..4fdad4fdc513c79375320b7691bfb23c25f79f65 100644 (file)
@@ -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.
index d5fbfe71bc4e24c47e80165b3cabe0f653bdab19..3a13afbd78c89903ac3f2560834badd467aa5bf0 100644 (file)
@@ -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.