On Wed, 24 Sep 2025 20:56:14 GMT, Roger Riggs <[email protected]> wrote:

>> David Beaumont has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   Manually deleting ImageReaderFactory (it returned somehow)
>
> src/java.base/share/classes/jdk/internal/jimage/ImageReader.java line 559:
> 
>> 557:             loc = findLocation(name.substring(MODULES_PREFIX.length()));
>> 558:             return ensureCachedIfNonNull(
>> 559:                     loc != null && loc.getType() == RESOURCE ? 
>> newResource(name, loc) : null);
> 
> It seems odd to test loc and type to produce a null and them pass it to a 
> method that will do nothing.
> The non-productive test can be done and return immediately.

Yeah, you're absolutely right, not sure what I was thinking there.

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

PR Review Comment: 
https://git.openjdk.org/valhalla/pull/1619#discussion_r2414665706

Reply via email to