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

Philip Race philip.race at oracle.com
Thu Nov 7 14:29:22 UTC 2019

The fix seems fine but if the app isn't setting null how are we getting 
null here ?
Frequent hierarchy validation does not in itself explain that to me.


On 11/6/19, 2:48 PM, Sergey Bylokhov wrote:
> Hello.
> 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.

More information about the awt-dev mailing list