mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 08:41:03 +00:00
Fix error handling UNC path
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@28145 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
39ad1c53d8
commit
cfd9c1205f
3 changed files with 32 additions and 19 deletions
|
@ -351,7 +351,6 @@ pathSepString()
|
|||
* 'C:/' absolute root for a drive on windows
|
||||
* 'C:' if entire path is 'C:' or 'C:relativepath'
|
||||
* '//host/share/' absolute root for a host and share on windows
|
||||
* '//host/share' if entire path is '//host/share'
|
||||
* '~/' home directory for user
|
||||
* '~' if entire path is '~'
|
||||
* '~username/' home directory for user
|
||||
|
@ -440,13 +439,12 @@ static unsigned rootOf(NSString *s, unsigned l)
|
|||
*/
|
||||
if (range.location > pos)
|
||||
{
|
||||
/* OK ... we have the '//host/share/'
|
||||
* format, so this is a valid UNC path.
|
||||
*/
|
||||
root = NSMaxRange(range);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
root = l;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue