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

java.io.File.equals should ignore "." elements when comparing paths

    XMLWordPrintable

Details

    • Bug
    • Resolution: Won't Fix
    • P3
    • None
    • 1.2.0
    • core-libs
    • None
    • generic
    • generic

    Description

      Seems like the following should be true, but are currently false:

      (new File("/a")).equals(new File("/a/."));
      (new File("/a/./foo.txt")).equals(new File("/a/foo.txt"))

      There are a couple of bugs outstanding against FilePermission that would
      be easier to fix if the above expressions returned true.

      Attachments

        Issue Links

          Activity

            People

              mr Mark Reinhold
              rschemersunw Roland Schemers (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: