RFR: 8331724: Refactor j.l.constant implementation to internal package [v6]

Chen Liang liach at openjdk.org
Thu May 9 02:44:58 UTC 2024


On Thu, 9 May 2024 02:28:16 GMT, ExE Boss <duke at openjdk.org> wrote:

>> Claes Redestad has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Validate after copying to avoid TOCTOU
>
> src/java.base/share/classes/jdk/internal/constant/MethodTypeDescImpl.java line 189:
> 
>> 187:         // Validate after copying to avoid TOCTOU
>> 188:         for (int i = pos; i < destPos; i++) {
>> 189:             validateArgument(argTypes[i]);
> 
> Suggestion:
> 
>             validateArgument(newArgs[i]);

Weird that this is not caught by MethodTypeDescTest.assertMethodType for no-arg method types.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/19105#discussion_r1594896764


More information about the core-libs-dev mailing list