On Thu, 24 Sep 2026 06:24:57 GMT, Prasanta Sadhukhan <[email protected]>
wrote:
>> test/jdk/javax/print/GetUIClassNameForRole.java line 44:
>>
>>> 42: for (PrintService service :
>>> 43: PrintServiceLookup.lookupPrintServices(null, null)) {
>>> 44: ServiceUIFactory factory = service.getServiceUIFactory();
>>
>> That should be
>> if (factory != null) { ... }
>
> It passes in CI without null check in all platforms...but anyways added null
> check
Of course it does, but the spec. says the method can return null. So without a
null check your code is incorrect.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/33009#discussion_r4096549007