aboutsummaryrefslogtreecommitdiff
path: root/zconf.h.in
diff options
context:
space:
mode:
authorMark Adler <madler@alumni.caltech.edu>2011-12-07 23:57:37 -0800
committerMark Adler <madler@alumni.caltech.edu>2011-12-08 00:13:52 -0800
commitafe7cf78d51b819dcdc5b0f4cb85a25a52a9fcd0 (patch)
tree24c9db96071504cd7beb1d1800dbb265c736070f /zconf.h.in
parentfbac04f666339eef3678e4eb81b25ae69bfcbd81 (diff)
downloadzlib-afe7cf78d51b819dcdc5b0f4cb85a25a52a9fcd0.tar.gz
zlib-afe7cf78d51b819dcdc5b0f4cb85a25a52a9fcd0.tar.bz2
zlib-afe7cf78d51b819dcdc5b0f4cb85a25a52a9fcd0.zip
Enable dictionary setting in middle of stream, and keeping the dictionary.
This patch adds the deflateResetKeep() function to retain the sliding window for the next deflate operation, and fixes an inflateResetKeep() problem that came from inflate() not updating the window when the stream completed. This enables constructing and decompressing a series of concatenated deflate streams where each can depend on the history of uncompressed data that precedes it. This generalizes deflateSetDictionary() and inflateSetDictionary() to permit setting the dictionary in the middle of a stream for raw deflate and inflate. This in combination with the Keep functions enables a scheme for updating files block by block with the transmission of compressed data, where blocks are sent with deflateResetKeep() to retain history for better compression, and deflateSetDictionary() is used for blocks already present at the receiver to skip compression but insert that data in the history, again for better compression. The corresponding inflate calls are done on the receiver side.
Diffstat (limited to 'zconf.h.in')
-rw-r--r--zconf.h.in1
1 files changed, 1 insertions, 0 deletions
diff --git a/zconf.h.in b/zconf.h.in
index 84ffb32..51c80ac 100644
--- a/zconf.h.in
+++ b/zconf.h.in
@@ -46,6 +46,7 @@
46# define deflatePending z_deflatePending 46# define deflatePending z_deflatePending
47# define deflatePrime z_deflatePrime 47# define deflatePrime z_deflatePrime
48# define deflateReset z_deflateReset 48# define deflateReset z_deflateReset
49# define deflateResetKeep z_deflateResetKeep
49# define deflateSetDictionary z_deflateSetDictionary 50# define deflateSetDictionary z_deflateSetDictionary
50# define deflateSetHeader z_deflateSetHeader 51# define deflateSetHeader z_deflateSetHeader
51# define deflateTune z_deflateTune 52# define deflateTune z_deflateTune