]> git.ipfire.org Git - thirdparty/zlib-ng.git/commit
Don't bother computing check value after successful inflateSync().
authorMark Adler <madler@alumni.caltech.edu>
Thu, 3 Jan 2019 02:10:40 +0000 (18:10 -0800)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Tue, 22 Oct 2019 07:57:38 +0000 (09:57 +0200)
commit33ce336b82f257689e7d20cee228fa61e079b90a
tree22fb309c87c76782d97f99ffc8c33b61ef2a38df
parentcf5959e11915d88e1b142fef3de359a1d443bd6d
Don't bother computing check value after successful inflateSync().

inflateSync() is used to skip invalid deflate data, which means
that the check value that was being computed is no longer useful.
This commit turns off the check value computation, and furthermore
allows a successful return if the compressed data terminated in a
graceful manner. This commit also fixes a bug in the case that
inflateSync() is used before a header is ever processed. In that
case, there is no knowledge of a trailer, so the remainder is
treated as raw.
inflate.c
inflate.h
test/example.c
test/fuzz/example_flush_fuzzer.c