diff options
author | Brad King <brad.king@kitware.com> | 2017-11-15 15:32:01 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-11-15 15:47:07 (GMT) |
commit | c871446abc9f9f33bd302ed059037d719eb9e2d9 (patch) | |
tree | 7189bca12aad188ed10b739f1c98607891bf7266 /Source/cmMakefile.cxx | |
parent | 1fe9e49bad0ad4f540ceda028106d9af89084946 (diff) | |
download | CMake-c871446abc9f9f33bd302ed059037d719eb9e2d9.zip CMake-c871446abc9f9f33bd302ed059037d719eb9e2d9.tar.gz CMake-c871446abc9f9f33bd302ed059037d719eb9e2d9.tar.bz2 |
cmSourceGroup: Return strings from GetName and GetFullName
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r-- | Source/cmMakefile.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index 4109b90..5a11a90 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -1950,7 +1950,7 @@ cmSourceGroup* cmMakefile::GetSourceGroup( // first look for source group starting with the same as the one we want for (cmSourceGroup const& srcGroup : this->SourceGroups) { - std::string sgName = srcGroup.GetName(); + std::string const& sgName = srcGroup.GetName(); if (sgName == name[0]) { sg = const_cast<cmSourceGroup*>(&srcGroup); break; @@ -2014,7 +2014,8 @@ void cmMakefile::AddSourceGroup(const std::vector<std::string>& name, } // build the whole source group path for (++i; i <= lastElement; ++i) { - sg->AddChild(cmSourceGroup(name[i].c_str(), nullptr, sg->GetFullName())); + sg->AddChild( + cmSourceGroup(name[i].c_str(), nullptr, sg->GetFullName().c_str())); sg = sg->LookupChild(name[i].c_str()); } |