Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8167988

java.nio.file.InvalidPathException if click button in JFileChooser demo of SwingSet2

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P2
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      b143

      Description

      Current 9 repo code throws exception when clicking on any one of three buttons in JFileChooser demo of SwingSet2:

      $ ./build/windows-x86_64-normal-server-release/jdk/bin/java -jar "c:/Users/Pete
      /Downloads/SwingSet2.jar"
      Exception in thread "AWT-EventQueue-0" java.nio.file.InvalidPathException: Illeg
      al char <:> at index 0: ::{20D04FE0-3AEA-1069-A2D8-08002B30309D}
              at sun.nio.fs.WindowsPathParser.normalize(java.base/WindowsPathParser.ja
      va:182)
              at sun.nio.fs.WindowsPathParser.parse(java.base/WindowsPathParser.java:1
      53)
              at sun.nio.fs.WindowsPathParser.parse(java.base/WindowsPathParser.java:7
      7)
              at sun.nio.fs.WindowsPath.parse(java.base/WindowsPath.java:92)
              at sun.nio.fs.WindowsFileSystem.getPath(java.base/WindowsFileSystem.java
      :229)
              at java.nio.file.Paths.get(java.base/Paths.java:84)
              at sun.awt.shell.ShellFolder.getShellFolder(java.desktop/ShellFolder.jav
      a:247)
              at javax.swing.filechooser.FileSystemView.getShellFolder(java.desktop/Fi
      leSystemView.java:658)
              at javax.swing.filechooser.FileSystemView.getSystemDisplayName(java.desk
      top/FileSystemView.java:195)
              at javax.swing.plaf.basic.BasicFileChooserUI$BasicFileView.getName(java.
      desktop/BasicFileChooserUI.java:1438)
              at javax.swing.JFileChooser.getName(java.desktop/JFileChooser.java:1528)

              at javax.swing.plaf.metal.MetalFileChooserUI$DirectoryComboBoxRenderer.g
      etListCellRendererComponent(java.desktop/MetalFileChooserUI.java:947)
              at javax.swing.plaf.basic.BasicListUI.updateLayoutState(java.desktop/Bas
      icListUI.java:1431)
              at javax.swing.plaf.basic.BasicListUI.maybeUpdateLayoutState(java.deskto
      p/BasicListUI.java:1381)
              at javax.swing.plaf.basic.BasicListUI$Handler.valueChanged(java.desktop/
      BasicListUI.java:2713)
              at javax.swing.DefaultListSelectionModel.fireValueChanged(java.desktop/D
      efaultListSelectionModel.java:196)
              at javax.swing.DefaultListSelectionModel.fireValueChanged(java.desktop/D
      efaultListSelectionModel.java:176)
              at javax.swing.DefaultListSelectionModel.fireValueChanged(java.desktop/D
      efaultListSelectionModel.java:223)
              at javax.swing.DefaultListSelectionModel.changeSelection(java.desktop/De
      faultListSelectionModel.java:420)
              at javax.swing.DefaultListSelectionModel.changeSelection(java.desktop/De
      faultListSelectionModel.java:430)
              at javax.swing.DefaultListSelectionModel.setSelectionInterval(java.deskt
      op/DefaultListSelectionModel.java:474)
              at javax.swing.JList.setSelectedIndex(java.desktop/JList.java:2205)
              at javax.swing.plaf.basic.BasicComboPopup.setListSelection(java.desktop/
      BasicComboPopup.java:1227)
              at javax.swing.plaf.basic.BasicComboPopup.access$300(java.desktop/BasicC
      omboPopup.java:64)
              at javax.swing.plaf.basic.BasicComboPopup$Handler.itemStateChanged(java.
      desktop/BasicComboPopup.java:1051)
              at javax.swing.JComboBox.fireItemStateChanged(java.desktop/JComboBox.jav
      a:1227)
              at javax.swing.JComboBox.selectedItemChanged(java.desktop/JComboBox.java
      :1287)
              at javax.swing.JComboBox.contentsChanged(java.desktop/JComboBox.java:133
      4)
              at javax.swing.AbstractListModel.fireContentsChanged(java.desktop/Abstra
      ctListModel.java:123)
              at javax.swing.plaf.metal.MetalFileChooserUI$DirectoryComboBoxModel.setS
      electedItem(java.desktop/MetalFileChooserUI.java:1103)
              at javax.swing.plaf.metal.MetalFileChooserUI$DirectoryComboBoxModel.addI
      tem(java.desktop/MetalFileChooserUI.java:1068)
              at javax.swing.plaf.metal.MetalFileChooserUI$DirectoryComboBoxModel.acce
      ss$800(java.desktop/MetalFileChooserUI.java:995)
              at javax.swing.plaf.metal.MetalFileChooserUI.doDirectoryChanged(java.des
      ktop/MetalFileChooserUI.java:718)
              at javax.swing.plaf.metal.MetalFileChooserUI.access$1100(java.desktop/Me
      talFileChooserUI.java:53)
              at javax.swing.plaf.metal.MetalFileChooserUI$5.propertyChange(java.deskt
      op/MetalFileChooserUI.java:807)
              at java.beans.PropertyChangeSupport.fire(java.desktop/PropertyChangeSupp
      ort.java:341)
              at java.beans.PropertyChangeSupport.firePropertyChange(java.desktop/Prop
      ertyChangeSupport.java:333)
              at java.beans.PropertyChangeSupport.firePropertyChange(java.desktop/Prop
      ertyChangeSupport.java:266)
              at java.awt.Component.firePropertyChange(java.desktop/Component.java:850
      5)
              at javax.swing.JFileChooser.setCurrentDirectory(java.desktop/JFileChoose
      r.java:595)
              at javax.swing.JFileChooser.<init>(java.desktop/JFileChooser.java:349)
              at javax.swing.JFileChooser.<init>(java.desktop/JFileChooser.java:295)
              at FileChooserDemo.createFileChooser(FileChooserDemo.java:129)
              at FileChooserDemo$2.actionPerformed(FileChooserDemo.java:148)
              at javax.swing.AbstractButton.fireActionPerformed(java.desktop/AbstractB
      utton.java:1967)
              at javax.swing.AbstractButton$Handler.actionPerformed(java.desktop/Abstr
      actButton.java:2308)
              at javax.swing.DefaultButtonModel.fireActionPerformed(java.desktop/Defau
      ltButtonModel.java:404)
              at javax.swing.DefaultButtonModel.setPressed(java.desktop/DefaultButtonM
      odel.java:261)
              at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(java.desktop
      /BasicButtonListener.java:269)
              at java.awt.Component.processMouseEvent(java.desktop/Component.java:6575
      )
              at javax.swing.JComponent.processMouseEvent(java.desktop/JComponent.java
      :3338)
              at java.awt.Component.processEvent(java.desktop/Component.java:6340)
              at java.awt.Container.processEvent(java.desktop/Container.java:2259)
              at java.awt.Component.dispatchEventImpl(java.desktop/Component.java:4959
      )
              at java.awt.Container.dispatchEventImpl(java.desktop/Container.java:2317
      )
              at java.awt.Component.dispatchEvent(java.desktop/Component.java:4791)
              at java.awt.LightweightDispatcher.retargetMouseEvent(java.desktop/Contai
      ner.java:4896)
              at java.awt.LightweightDispatcher.processMouseEvent(java.desktop/Contain
      er.java:4533)
              at java.awt.LightweightDispatcher.dispatchEvent(java.desktop/Container.j
      ava:4474)
              at java.awt.Container.dispatchEventImpl(java.desktop/Container.java:2303
      )
              at java.awt.Window.dispatchEventImpl(java.desktop/Window.java:2758)
              at java.awt.Component.dispatchEvent(java.desktop/Component.java:4791)
              at java.awt.EventQueue.dispatchEventImpl(java.desktop/EventQueue.java:76
      1)
              at java.awt.EventQueue.access$500(java.desktop/EventQueue.java:97)
              at java.awt.EventQueue$3.run(java.desktop/EventQueue.java:712)
              at java.awt.EventQueue$3.run(java.desktop/EventQueue.java:706)
              at java.security.AccessController.doPrivileged(java.base/Native Method)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
      rivilege(java.base/ProtectionDomain.java:78)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
      rivilege(java.base/ProtectionDomain.java:88)
              at java.awt.EventQueue$4.run(java.desktop/EventQueue.java:734)
              at java.awt.EventQueue$4.run(java.desktop/EventQueue.java:732)
              at java.security.AccessController.doPrivileged(java.base/Native Method)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
      rivilege(java.base/ProtectionDomain.java:78)
              at java.awt.EventQueue.dispatchEvent(java.desktop/EventQueue.java:731)
              at java.awt.EventDispatchThread.pumpOneEventForFilters(java.desktop/Even
      tDispatchThread.java:199)
              at java.awt.EventDispatchThread.pumpEventsForFilter(java.desktop/EventDi
      spatchThread.java:124)
              at java.awt.EventDispatchThread.pumpEventsForHierarchy(java.desktop/Even
      tDispatchThread.java:113)
              at java.awt.EventDispatchThread.pumpEvents(java.desktop/EventDispatchThr
      ead.java:109)
              at java.awt.EventDispatchThread.pumpEvents(java.desktop/EventDispatchThr
      ead.java:101)
              at java.awt.EventDispatchThread.run(java.desktop/EventDispatchThread.jav
      a:90)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                prr Philip Race
                Reporter:
                ptbrunet Pete Brunet (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                8 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: