diff options
author | Stephen Kelly <steveire@gmail.com> | 2013-12-30 15:09:46 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2014-01-06 17:46:44 (GMT) |
commit | 802a28fc5e19136b947b2f7d136de31c1d10b578 (patch) | |
tree | 1c3e13b743830a9ec2a42b49165d2536843afdfb /Source/cmFindPackageCommand.cxx | |
parent | dc08199848c20c7f76a68dbf54a85c736809ac57 (diff) | |
download | CMake-802a28fc5e19136b947b2f7d136de31c1d10b578.zip CMake-802a28fc5e19136b947b2f7d136de31c1d10b578.tar.gz CMake-802a28fc5e19136b947b2f7d136de31c1d10b578.tar.bz2 |
Add cmHasLiteralSuffix API.
Diffstat (limited to 'Source/cmFindPackageCommand.cxx')
-rw-r--r-- | Source/cmFindPackageCommand.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/cmFindPackageCommand.cxx b/Source/cmFindPackageCommand.cxx index 55c20d6..12bb807 100644 --- a/Source/cmFindPackageCommand.cxx +++ b/Source/cmFindPackageCommand.cxx @@ -1151,8 +1151,8 @@ void cmFindPackageCommand::AddPrefixesSystemEnvironment() std::string const& d = *i; // If the path is a PREFIX/bin case then add its parent instead. - if((d.size() >= 4 && strcmp(d.c_str()+d.size()-4, "/bin") == 0) || - (d.size() >= 5 && strcmp(d.c_str()+d.size()-5, "/sbin") == 0)) + if((cmHasLiteralSuffix(d, "/bin")) || + (cmHasLiteralSuffix(d, "/sbin"))) { this->AddPathInternal(cmSystemTools::GetFilenamePath(d), EnvPath); } |