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

(fs) Path.relativize() gives incorrect result for ".."

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: core-libs
    • Subcomponent:
    • Resolved In Build:
      b134

      Description

      Paths.get("..").relativize(Paths.get("x")) returns "../x", while actually it should be the "current working directory/x". Of course we don't know what cwd is, so maybe an IAE should be thrown.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                alanb Alan Bateman
                Reporter:
                weijun Weijun Wang
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: