On Fri, 2 Aug 2024 00:22:00 GMT, Harshitha Onkar <[email protected]> wrote:
>> test/jdk/javax/swing/JOptionPane/OptionPaneInput.java line 89: >> >>> 87: f.setVisible(true); >>> 88: >>> 89: JOptionPane.showMessageDialog(null, t); >> >> Since parentComponent of JOptionPane is null running into NPE. >> >> >> parentComponent.revalidate(); >> parentComponent.repaint(); > > The fix should handle both cases - when parentComponent is null and not null. > With current fix, if there is a case when parentComponent is null, we will > run into NPE. added null check ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/20359#discussion_r1704431617
