Proposed fix for JDK-8028804 (Deflater.deflateBytes() may produce corrupted output on Deflater level/strategy change)
Thomas Stüfe
thomas.stuefe at gmail.com
Wed Nov 27 08:33:59 UTC 2013
>
>
> My personal view is that we should link to libz where possible (already
> so on Mac, but not the default on Linux or Solaris). Clearly we still have
> to allow for platforms where it doesn't exist (Windows only I think) and in
> that case we should periodically update it (as we did in both JDK 7 and JDK
> 8). It may be time to look at upgrading it again (for JDK 9 as this is not
> something to touch in the end-game of a release).
>
>
I can see arguments for both sides (linking statically vs using the system
zlib) and I'm leaning toward the former. Errors or incompatibilities in the
zlib could be really harmful, and I rather use the zlib I ran all my tests
with instead of the system zlib which may or may not be out of date or show
regressions.
So, if I were to recode this fix again to not change the zlib - which is
not so trivial - do you think there is a chance that this fix gets examined
and maybe pulled into the OpenJDK?
..Thomas
More information about the core-libs-dev
mailing list