diff options
author | Mark Adler <madler@alumni.caltech.edu> | 2012-01-13 23:54:40 -0600 |
---|---|---|
committer | Mark Adler <madler@alumni.caltech.edu> | 2012-01-13 23:54:40 -0600 |
commit | 4f5779a8e78e0b1c8b1ecdea88d8456dada17823 (patch) | |
tree | 267f14f252dbc3f23e8c7f34a7ddce633491754e /deflate.h | |
parent | 0b828b4aa6c962ab46eae624578d77b35395b2c1 (diff) | |
download | zlib-4f5779a8e78e0b1c8b1ecdea88d8456dada17823.tar.gz zlib-4f5779a8e78e0b1c8b1ecdea88d8456dada17823.tar.bz2 zlib-4f5779a8e78e0b1c8b1ecdea88d8456dada17823.zip |
Insert the first two strings in the hash table after a flush.
This allows deflate to generate the same output when continuing after
a Z_SYNC_FLUSH vs. using deflateSetDictionary() after a Z_FULL_FLUSH
or a deflateReset(). It also slightly improves compression when
flushing by providing two more strings to possibly match at the start
of the new block.
Diffstat (limited to 'deflate.h')
-rw-r--r-- | deflate.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -247,6 +247,7 @@ typedef struct internal_state { | |||
247 | ulg opt_len; /* bit length of current block with optimal trees */ | 247 | ulg opt_len; /* bit length of current block with optimal trees */ |
248 | ulg static_len; /* bit length of current block with static trees */ | 248 | ulg static_len; /* bit length of current block with static trees */ |
249 | uInt matches; /* number of string matches in current block */ | 249 | uInt matches; /* number of string matches in current block */ |
250 | uInt insert; /* bytes at end of window left to insert */ | ||
250 | 251 | ||
251 | #ifdef DEBUG | 252 | #ifdef DEBUG |
252 | ulg compressed_len; /* total bit length of compressed file mod 2^32 */ | 253 | ulg compressed_len; /* total bit length of compressed file mod 2^32 */ |