aboutsummaryrefslogtreecommitdiffstats
path: root/lib/System/Win32
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-08-12 17:47:06 +0000
committerChris Lattner <sabre@nondot.org>2009-08-12 17:47:06 +0000
commita79eefd4f862af68dc9e77bed537581aa4f5f806 (patch)
treea2b4d1fb01c397872e92da456290eb858baedefd /lib/System/Win32
parent871fc2eaa06393eaceb7adfc5f054b8ba08df142 (diff)
downloadexternal_llvm-a79eefd4f862af68dc9e77bed537581aa4f5f806.zip
external_llvm-a79eefd4f862af68dc9e77bed537581aa4f5f806.tar.gz
external_llvm-a79eefd4f862af68dc9e77bed537581aa4f5f806.tar.bz2
improve win32 path support, patch by Baptiste Lepilleur!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78823 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/System/Win32')
-rw-r--r--lib/System/Win32/Path.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/System/Win32/Path.inc b/lib/System/Win32/Path.inc
index 80c7bd9..fccf001 100644
--- a/lib/System/Win32/Path.inc
+++ b/lib/System/Win32/Path.inc
@@ -156,7 +156,8 @@ Path::isAbsolute(const char *NameStart, unsigned NameLen) {
case 2:
return NameStart[0] == '/';
default:
- return NameStart[0] == '/' || (NameStart[1] == ':' && NameStart[2] == '/');
+ return (NameStart[0] == '/' || (NameStart[1] == ':' && NameStart[2] == '/')) ||
+ (NameStart[0] == '\\' || (NameStart[1] == ':' && NameStart[2] == '\\'));
}
}