diff options
author | Michael J. Spencer <bigcheesegs@gmail.com> | 2010-12-06 04:28:23 +0000 |
---|---|---|
committer | Michael J. Spencer <bigcheesegs@gmail.com> | 2010-12-06 04:28:23 +0000 |
commit | 95e4ac16a5bd7d442b45bc6bc0fd2a994bb5c7a9 (patch) | |
tree | f4053efe03ed9eb5d1310d8e7501ebea9d63a442 /llvm/lib/Support/PathV2.cpp | |
parent | 39c4621f42de732014413de1c982ca279429ac30 (diff) | |
download | bcm5719-llvm-95e4ac16a5bd7d442b45bc6bc0fd2a994bb5c7a9.tar.gz bcm5719-llvm-95e4ac16a5bd7d442b45bc6bc0fd2a994bb5c7a9.zip |
Support/PathV2: Fix append to not add a slash to empty or root paths.
llvm-svn: 120988
Diffstat (limited to 'llvm/lib/Support/PathV2.cpp')
-rw-r--r-- | llvm/lib/Support/PathV2.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Support/PathV2.cpp b/llvm/lib/Support/PathV2.cpp index 2c1d92dbcac..73896edecce 100644 --- a/llvm/lib/Support/PathV2.cpp +++ b/llvm/lib/Support/PathV2.cpp @@ -413,7 +413,7 @@ error_code append(SmallVectorImpl<char> &path, const Twine &a, continue; } - if (!component_has_sep && !(path.empty() && is_root_name)) { + if (!component_has_sep && !(path.empty() || is_root_name)) { // Add a separator. path.push_back(prefered_separator); } |