On Sat, 24 Feb 2024 17:15:02 GMT, Eirik Bjørsnøs <eir...@openjdk.org> wrote:
> Since the CSR is already approved, I'll add a question here: > > `ZipFile` performs a lot of validation while opening ZIP files, including > throwning ZipException for invalid entry names or comments. Why handle the > ZIP file comment differently (lazily)? If this comment was also validated by > the constructor, then the API change for ZipFile::getComment would not be > needed. > > Do we have reason to belive the encoding quality of ZIP file comments is less > reliable than that of ZIP entry comments? Or is there some other reason this > validation is done lazily? Yes, there are some libraries/tools that are using the Zip file comment for its own purposes such as idea_rt.jar which is part of IntelliJ. ------------- PR Comment: https://git.openjdk.org/jdk/pull/17995#issuecomment-1962571347