<AWT Dev> [14] Review Request: 8233657 Intermittent NPE in Component.validate()

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Wed Nov 6 22:48:25 UTC 2019

Please review the fix for JDK 14.

Bug: https://bugs.openjdk.java.net/browse/JDK-8233657
Fix: http://cr.openjdk.java.net/~serb/8233657/webrev.00

During testsprint I have analyzed some intermittent failures of our tests and
found some intermittent NPE. The root cause is the calling of Component.validate()
if the null font is used. The bug reproduced mostly on HiDPI systems where we
validate the hierarchy of components more often.

The validate method is aupdated to use the same logic as setFont(), where null value
is ignored and never passed to the peer.

Actually the fix is simpler than the tests problem listing due to product bug.

Best regards, Sergey.

More information about the awt-dev mailing list