RFR: 8313765: Invalid CEN header (invalid zip64 extra data field size) [v2]
Lance Andersen
lancea at openjdk.org
Tue Aug 15 15:44:36 UTC 2023
On Tue, 15 Aug 2023 10:36:47 GMT, Alan Bateman <alanb at openjdk.org> wrote:
>> I don't think this is a question of "taste" because `isZip64ExtBlockSizeValid()` suggests that the method will check for *valid* sizes and to my understanding `0` is not a valid input. This method might also be called from other places in the future which do not handle the zero case appropriately.
>>
>> In any case, I'm ready to accept this as a case of "Disagree and Commit" :) but in that case please update at least the comment below to something like "*..Note we do not need to check blockSize is >= 8 as we know its length is at least 8 by now*" because "*..from the call to isZip64ExtBlockSizeValid()*" isn't true any more.
>
> I think I agree with Volker that it would be better if isZip64ExtBlockSizeValid continued to return false for block size 0.
OK, I have made the suggest change that you both prefer.
Thank you for your input
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15273#discussion_r1294792855
More information about the core-libs-dev
mailing list