--- old/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java 2019-05-02 04:34:40.000000000 -0700 +++ new/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java 2019-05-02 04:34:40.000000000 -0700 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2019, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1269,7 +1269,7 @@ super(FilePane.ACTION_EDIT_FILE_NAME); } public void actionPerformed(ActionEvent e) { - if (getFileName().equals("")) { + if (getFileName().isEmpty()) { return; } JFileChooser fc = getFileChooser();