< prev index next >

## src/java.desktop/share/classes/sun/awt/shell/ShellFolder.java

Print this page

    *** 242,252 ****
          public static ShellFolder getShellFolder(File file) throws FileNotFoundException {
              if (file instanceof ShellFolder) {
                  return (ShellFolder)file;
              }

    !         if (!Files.exists(Paths.get(file.getPath()), LinkOption.NOFOLLOW_LINKS)) {
                  throw new FileNotFoundException();
              }
              return shellFolderManager.createShellFolder(file);
          }

    --- 242,256 ----
          public static ShellFolder getShellFolder(File file) throws FileNotFoundException {
              if (file instanceof ShellFolder) {
                  return (ShellFolder)file;
              }

    !         try {
    !             if (!Files.exists(Paths.get(file.getCanonicalPath()), LinkOption.NOFOLLOW_LINKS)) {
    !                 throw new FileNotFoundException();
    !             }
    !         } catch (IOException ex) {
                  throw new FileNotFoundException();
              }
              return shellFolderManager.createShellFolder(file);
          }

< prev index next >