aboutsummaryrefslogtreecommitdiff
path: root/lib/Support/Unix/Path.inc
diff options
context:
space:
mode:
authorMichael J. Spencer <bigcheesegs@gmail.com>2011-01-11 01:21:55 +0000
committerMichael J. Spencer <bigcheesegs@gmail.com>2011-01-11 01:21:55 +0000
commit218dc3e2fe54c28b0292a3e89c5ed6563f62ac23 (patch)
tree14d22d940fea2720c93383a5f2dbda16488d2053 /lib/Support/Unix/Path.inc
parent121704d738f9de8aaf04b144dcf493130fbfee3d (diff)
Support/Path: Deprecate PathV1::isDirectory and replace all uses with PathV2::is_directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123209 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/Unix/Path.inc')
-rw-r--r--lib/Support/Unix/Path.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Support/Unix/Path.inc b/lib/Support/Unix/Path.inc
index b39e465a53..bdd13a64b0 100644
--- a/lib/Support/Unix/Path.inc
+++ b/lib/Support/Unix/Path.inc
@@ -823,7 +823,8 @@ Path::makeUnique(bool reuse_current, std::string* ErrMsg) {
Buf.resize(path.size()+8);
char *FNBuffer = &Buf[0];
path.copy(FNBuffer,path.size());
- if (isDirectory())
+ bool isdir;
+ if (!fs::is_directory(path, isdir) && isdir)
strcpy(FNBuffer+path.size(), "/XXXXXX");
else
strcpy(FNBuffer+path.size(), "-XXXXXX");