On Mon, 5 Jan 2026 17:52:39 GMT, Alan Bateman <[email protected]> wrote:
>> David Beaumont has updated the pull request incrementally with one
>> additional commit since the last revision:
>>
>> actually remove the class ...
>
> src/java.base/share/classes/jdk/internal/jimage/BasicImageReader.java line
> 392:
>
>> 390: private static ByteBuffer allocateBuffer(long size) {
>> 391: if (size < 0 || Integer.MAX_VALUE < size) {
>> 392: throw new IndexOutOfBoundsException("size");
>
> I don't think it can happen but I assume IAE would be more appropriate here
> as size is not an index.
Only needs to check for the `Integer.MAX_VALUE` in any case, as
`ByteBuffer::allocateDirect` throws on `size < 0`. It also uses IAE
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/29043#discussion_r2662538975