Closed thomaslevesque closed 8 years ago
I need to look into UNC support; more than likely a fair amount of work :)
Have you decided if you'll be extending support to UNC paths? I'm currently in a situation where I scan shares via the UNC path and I'm running into issues with long paths and filenames.
I believe the latest changes and passing tests mean that UNCs are now supported. I would appreciate if someone could try out some of the issues they've ad with UNCs prior.
Thanks.
@peteraritchie are you still wanting results?... I'm about to use this for a lot of work with UNCs so can let you know how it goes in a week or so?
No thanks
JJ On Apr 7, 2015 12:29 PM, "Chris Wilson" notifications@github.com wrote:
@peteraritchie https://github.com/peteraritchie are you still wanting results?... I'm about to use this for a lot of work with UNCs so can let you know how it goes in a week or so?
— Reply to this email directly or view it on GitHub https://github.com/peteraritchie/LongPath/issues/9#issuecomment-90633545 .
JJ I was referencing Peter's comment after yours. Sorry if I was unclear.
@FuchsiaSoft yeah, the code should work now with UNCs; I haven't had the time to get too deep into testing it (moved to a different country :) ). If there's something blocking you, let me know.
Hi, I am having a problem with the UNC support. I have the following path in a variable: \10.24.0.11\Deployments\Backups\AndroidBuilder
That directory exists, but when checking with Directory.Exists("\10.24.0.11\Deployments\Backups\AndroidBuilder") it doesn't find this path. Then it goes into the next line, which is Directory.CreateDirectory("\10.24.0.11\Deployments\Backups\AndroidBuilder"), and this one fails due to this error: {"The UNC path should be of the form \server\share."}.
Obviously there is lack of UNC support, and I couldn't fully understand why it fails.
Would love to get assistance with this one.
Thanks, Ido
I'm not clear on your question. "\10.24.0.11\Deployments\Backups\AndroidBuilder" is not a valid UNC. UNCs must start with "\", which is what is detailed in the error.
yea, sorry, it was a wrong Paste. it is \10.24.0.11...
Huh? that's still missing a slash
ahhhh for some reason github removes double slashes :) its \10.24.0.11\deployments\
UNC paths aren't working for me either. I think the problem is that the long path format for UNC paths is a little different... \\server\share
should be formatted as \\?\UNC\server\share
.
Are you planning to check the PR for the UNC paths? Also, are you planning to release a new version?
I have been testing with pull request #27 and it does seam to work for long UNC paths. The only issue I has was a path that was exactly MAXPATH in length
@NeilWhitworth What issue did you have with a path that was exactly MAXPATH?
Assuming this is working now
Path.GetPathRoot(@"\\server\foo\bar\baz.txt")
should return\\server\foo
, but it returns\\
instead