diff options
author | Mikhail Glushenkov <foldr@codedgers.com> | 2010-10-28 19:33:04 +0000 |
---|---|---|
committer | Mikhail Glushenkov <foldr@codedgers.com> | 2010-10-28 19:33:04 +0000 |
commit | fdba1308ee17366f4ec0251f2bcb4d4a1ea0fb19 (patch) | |
tree | 250c7cd93e1742e4ffc903fd5c7f22925d276362 /llvm/lib/Support/SystemUtils.cpp | |
parent | d7faab5c9578cb66827cc9b44d548fed31d5b358 (diff) | |
download | bcm5719-llvm-fdba1308ee17366f4ec0251f2bcb4d4a1ea0fb19.tar.gz bcm5719-llvm-fdba1308ee17366f4ec0251f2bcb4d4a1ea0fb19.zip |
Remove an unnecessary check and an unnecessary temporary.
llvm-svn: 117583
Diffstat (limited to 'llvm/lib/Support/SystemUtils.cpp')
-rw-r--r-- | llvm/lib/Support/SystemUtils.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Support/SystemUtils.cpp b/llvm/lib/Support/SystemUtils.cpp index c8b260c2e3d..820e7cfbb17 100644 --- a/llvm/lib/Support/SystemUtils.cpp +++ b/llvm/lib/Support/SystemUtils.cpp @@ -56,10 +56,9 @@ sys::Path llvm::FindExecutable(const std::string &ExeName, // version of the program. if (Result.isAbsolute()) { Result = sys::Program::FindProgramByName(Result.str()); - if (!Result.empty()) - return Result; + return Result; } } - return sys::Path(); + return Result; } |