New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8276661: (fs) UserDefinedFileAttributeView no longer works with long path (win) #6435
8276661: (fs) UserDefinedFileAttributeView no longer works with long path (win) #6435
Conversation
The test fails without the proposed implementation change but passes with the change. |
👋 Welcome back bpb! A progress list of the required criteria for merging this PR into |
Webrevs
|
The test passes locally but has some problem when run in the CI and fails with a message like this:
|
test/jdk/java/nio/file/attribute/UserDefinedFileAttributeView/Basic.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the updates.
@bplb This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 22 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
Without commit 04, |
All tiers in the CI pass on Windows. |
The latest iteration is 5703b01 which adds a pad count to the API exposed by WindowsPath. I think we need to bury that. The previous iteration with getPathForWin32Calls and getPathWithPrefixForWin32Calls was much cleaner. For the discussion it would be useful to know if test failure was due to MAX_LONG_PATH and whether the limit includes the colon and the stream name. |
Merged code passes tiers 1-3 tests in the CI. |
The latest revision looks good and I think we were lucky that the CheckPermissions test caught the issue. One suggestion is to invert forceLongPrefix to something like allowShortPath. I think this would make getPathForWin32Calls a bit easier to read because because it avoid two uses of !forceLongPrefix. |
/integrate |
Going to push as commit 15345e3.
Your commit was automatically rebased without conflicts. |
} | ||
|
||
// cache the resolved path (except drive relative paths as the working | ||
// directory on removal media devices can change during the lifetime | ||
// of the VM) | ||
if (type != WindowsPathType.DRIVE_RELATIVE) { | ||
if (allowShortPath && type != WindowsPathType.DRIVE_RELATIVE) { | ||
synchronized (this) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm. Why do we need this synchronized
here? Seems redundant for me.
Please consider this change which uses a new method
WindowsPath::getPathWithPrefixForWin32Calls
.Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/6435/head:pull/6435
$ git checkout pull/6435
Update a local copy of the PR:
$ git checkout pull/6435
$ git pull https://git.openjdk.java.net/jdk pull/6435/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 6435
View PR using the GUI difftool:
$ git pr show -t 6435
Using diff file
Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/6435.diff