RFR: 8287843: File::getCanonicalFile doesn't work for \\?\C:\ style paths DOS device paths [v8]
Alan Bateman
alanb at openjdk.org
Mon Nov 13 19:52:18 UTC 2023
On Mon, 13 Nov 2023 19:41:48 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:
>> In the Windows implementation of java.io.File.getCanonicalPath, strip any long path or UNC prefix before canonicalizing the remainder of the pathname.
>
> Brian Burkhalter has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains 11 additional commits since the last revision:
>
> - 8287843: Change tests as suggested in review
> - Merge
> - 8287843: Remove unused constant and method from WindowsPrefixes test
> - 8287843: remove stripLongOrUNCPrefix() except in normalize()
> - 8287843: Strip prefix in more methods; remove bad test case
> - 8287843: Add WindowsPrefixes test
> - 8287843: Convert GetAbsolutePath and IsAbsolute tests to JUnit and add some test cases
> - 8287843: Move prefix stripping to separate method; add to isAbsolute
> - 8287843: Move \\?\ prefix stripping to resolve(File)
> - 8287843: Handle "\\?\UNC"; add bad paths to test
> - ... and 1 more: https://git.openjdk.org/jdk/compare/f6b98c0c...2f313185
I don't have any other comments on this. I assume you'll run the tests a number of times to make sure they are stable.
-------------
Marked as reviewed by alanb (Reviewer).
PR Review: https://git.openjdk.org/jdk/pull/15603#pullrequestreview-1728139348
More information about the core-libs-dev
mailing list