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

File should check if separator needed

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.1
    • 1.0.2
    • core-libs
    • 1.1fcs
    • sparc
    • solaris_2.5
    • Not verified

      When composing a File from a path and a name, the constructor
      should check if the path already ends in a separator, to avoid getting
      double separators between path and name.


         public File(String path, String name) {
      this((path != null) ? path + separator + name : name);
         }

            djbrown David Brown (Inactive)
            jjg Jonathan Gibbons
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: