RFR: 8308588: Unnecessary synchronized on GTKStyle#ICONS_MAP can be removed
Abhishek Kumar
abhiscxk at openjdk.org
Thu Aug 29 11:56:20 UTC 2024
On Thu, 29 Aug 2024 05:26:47 GMT, Abhishek Kumar <abhiscxk at openjdk.org> wrote:
> FWIW, Running tests on linux environment will test it on default MetalL&F which will not test this GTK path unless you specify GTK L&F in `swing.defaultlaf` to it
@prsadhuk Ran the tests with GTK Look and Feel option in CI and the tests failed with or without fix is same except one test failure `JFrameMenuSerializationTest.java`. This test failed with the exception `Exception: java.lang.NullPointerException: Cannot invoke "javax.swing.plaf.synth.SynthStyle.getColor(javax.swing.plaf.synth.SynthContext, javax.swing.plaf.synth.ColorType)" because "style" is null` when run without the fix.
However, I checked the test result without fix in CI pipeline and the test result shows it passed but the html log file shows `java.lang.NullPointerException: Cannot invoke "javax.swing.plaf.synth.SynthStyle.getColor(javax.swing.plaf.synth.SynthContext, javax.swing.plaf.synth.ColorType)" because "style" is null` under System.err output.
Checked in my local machine and this test fails with the same exception.
I think this is not related with the fix proposed here because it seems the **GTKStyle object itself is null** if it is run with GTK L&F option.
Added the CI link when tests are ran with GTK L&F option in JBS.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/20741#issuecomment-2317432908
More information about the client-libs-dev
mailing list