mirror of
https://github.com/clechasseur/pathcopycopy.git
synced 2026-04-25 12:15:58 +03:00
[GH-ISSUE #127] [BUG] Long UNC Path (follow symlink) contains stray string #126
Labels
No labels
bug
duplicate
enhancement
enhancement
enhancement
fixed
help wanted
help wanted
invalid
pull-request
question
waiting for input
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/pathcopycopy#126
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @jackhab on GitHub (Aug 11, 2020).
Original GitHub issue: https://github.com/clechasseur/pathcopycopy/issues/127
Originally assigned to: @clechasseur on GitHub.
Describe the bug
The symlink path resolution works fine but the path contains stray string which makes the path unusable.
Symlinks pointing to network location contain "?\UNC".
Symlinks pointing to local drives contain "\\?".
For example:
Symlink to network: \\?\UNC\dc2012\system\mail
Symlink to local drive: \\?\C:\Users\User\OneDrive
To Reproduce
Enable Long UNC Path (follow symlink) in Settings.
Map a location via symbolic link in command line:
mklink /d LinkedPath c:\some\path
Explorer > right click LinkedPath > Path Copy > Examine the path
Expected behavior
\\dc2012\system\mail
C:\Users\User\OneDrive
Software
Path Copy Copy Version 19.0
@clechasseur commented on GitHub (Aug 11, 2020):
This is actually a valid path. See
https://docs.microsoft.com/en-us/dotnet/standard/io/file-path-formats#example-ways-to-refer-to-the-same-file
@jackhab commented on GitHub (Aug 11, 2020):
This is a valid path from Windows API point of view, but since this utility is used in Windows Explorer the ultimate validity test, IMHO, should be whether the path can pasted back to Explorer path drop-down or into File Open dialog box.
The only program which I've found to accept these paths is PowerShell.
@clechasseur commented on GitHub (Aug 11, 2020):
It's strange that it doesn't work - you're right, they need to be usable through Explorer. I'll look into it.
@clechasseur commented on GitHub (Feb 13, 2021):
This bug is fixed. The next release should no longer copy non-working paths.