<AWT Dev> [14] Review Request: 8235638 NPE in LWWindowPeer.getOnscreenGraphics()

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Tue Dec 10 19:32:10 UTC 2019

Please review the fix for JDK 14.

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

I have found a root cause of intermittent failures of some stress tests in the JDK on macOS.
Such tests usually show/hide a lot of frames, and fails because of NPE in the
The reason is incorrect null check. We should read the surfaceData to the local var apply a
null check and then use it, otherwise, the data may be changed to null after the check.

Best regards, Sergey.

More information about the awt-dev mailing list