diff options
author | Reid Spencer <rspencer@reidspencer.com> | 2004-12-13 07:51:07 +0000 |
---|---|---|
committer | Reid Spencer <rspencer@reidspencer.com> | 2004-12-13 07:51:07 +0000 |
commit | 3d595cba33a8b2f9c92bc7887078fc7d4b486559 (patch) | |
tree | 99ad13d53501107f7010923ec8780d0b3480f0f1 /lib/System/Unix | |
parent | 07941b493dfeb11996690cfa2fc14c7c0bd7bb91 (diff) |
Remove an always false clause from an if statement.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18885 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/System/Unix')
-rw-r--r-- | lib/System/Unix/Path.cpp | 2 | ||||
-rw-r--r-- | lib/System/Unix/Path.inc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/System/Unix/Path.cpp b/lib/System/Unix/Path.cpp index 4b5ccb9344..6e07427608 100644 --- a/lib/System/Unix/Path.cpp +++ b/lib/System/Unix/Path.cpp @@ -290,7 +290,7 @@ Path::setDirectory(const std::string& a_path) { Path save(*this); path = a_path; size_t last = a_path.size() -1; - if (a_path.size() == 0 || a_path[last] != '/') + if (a_path[last] != '/') path += '/'; if (!isValid()) { path = save.path; diff --git a/lib/System/Unix/Path.inc b/lib/System/Unix/Path.inc index 4b5ccb9344..6e07427608 100644 --- a/lib/System/Unix/Path.inc +++ b/lib/System/Unix/Path.inc @@ -290,7 +290,7 @@ Path::setDirectory(const std::string& a_path) { Path save(*this); path = a_path; size_t last = a_path.size() -1; - if (a_path.size() == 0 || a_path[last] != '/') + if (a_path[last] != '/') path += '/'; if (!isValid()) { path = save.path; |