RFR: 8377461: Add ZipFile test for incorrect number of entries reported in ENDTOT [v2]
Eirik Bjørsnøs
eirbjo at openjdk.org
Tue Feb 10 06:05:17 UTC 2026
On Mon, 9 Feb 2026 19:02:45 GMT, Lance Andersen <lancea at openjdk.org> wrote:
>> Eirik Bjørsnøs has updated the pull request incrementally with two additional commits since the last revision:
>>
>> - Add case: Empty ZIP, correct ENDTOT
>> - Copyright 2026 for new test
>
> test/jdk/java/util/zip/ZipFile/IncorrectEndTot.java line 2:
>
>> 1: /*
>> 2: * Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
>
> I believe this is a new Test so 2026 is what we need for the copyright
Thanks for catching this copy/paste :-)
> test/jdk/java/util/zip/ZipFile/IncorrectEndTot.java line 60:
>
>> 58: Arguments.of(10, 11), // CEN has one less than ENDTOT
>> 59: Arguments.of(11, 10), // CEN has one more than ENDTOT
>> 60: Arguments.of(0, 10) // No CEN entries (empty ZIP)
>
> Should you include Arguments.of(0, 0) to test an empty ZIP?
Good idea. Added a normal case for empty ZIP.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/29635#discussion_r2785963555
PR Review Comment: https://git.openjdk.org/jdk/pull/29635#discussion_r2785964614
More information about the core-libs-dev
mailing list