summaryrefslogtreecommitdiffstats
path: root/Source/cmFindPathCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmFindPathCommand.cxx')
-rw-r--r--Source/cmFindPathCommand.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmFindPathCommand.cxx b/Source/cmFindPathCommand.cxx
index 53531dd..6280187 100644
--- a/Source/cmFindPathCommand.cxx
+++ b/Source/cmFindPathCommand.cxx
@@ -106,7 +106,7 @@ bool cmFindPathCommand::InitialPass(std::vector<std::string> const& argsIn)
i != this->SearchPaths.end(); ++i)
{
std::string& p = *i;
- if(p[p.size()-1] != '/')
+ if(p.empty() || p[p.size()-1] != '/')
{
p += "/";
}