summaryrefslogtreecommitdiffstats
path: root/Source/cmQtAutoGenInitializer.cxx
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2018-07-11 14:58:48 (GMT)
committerSebastian Holtermann <sebholt@xwmw.org>2018-07-11 14:58:48 (GMT)
commit86b332c25d22f7050ed60c1604c2a188c5885619 (patch)
treea24e0c71065919d0e2171b85c4b789526277ddbd /Source/cmQtAutoGenInitializer.cxx
parent189f723509a5077d044510e90b01775e2997302a (diff)
downloadCMake-86b332c25d22f7050ed60c1604c2a188c5885619.zip
CMake-86b332c25d22f7050ed60c1604c2a188c5885619.tar.gz
CMake-86b332c25d22f7050ed60c1604c2a188c5885619.tar.bz2
Return std::string from cmGeneratorTarget::ImportedGetLocation
Diffstat (limited to 'Source/cmQtAutoGenInitializer.cxx')
-rw-r--r--Source/cmQtAutoGenInitializer.cxx11
1 files changed, 3 insertions, 8 deletions
diff --git a/Source/cmQtAutoGenInitializer.cxx b/Source/cmQtAutoGenInitializer.cxx
index a0fd1b1..fd9829f 100644
--- a/Source/cmQtAutoGenInitializer.cxx
+++ b/Source/cmQtAutoGenInitializer.cxx
@@ -37,11 +37,6 @@
#include <utility>
#include <vector>
-inline static const char* SafeString(const char* value)
-{
- return (value != nullptr) ? value : "";
-}
-
static std::size_t GetParallelCPUCount()
{
static std::size_t count = 0;
@@ -1268,7 +1263,7 @@ bool cmQtAutoGenInitializer::GetMocExecutable()
cmLocalGenerator* localGen = this->Target->GetLocalGenerator();
cmGeneratorTarget* tgt = localGen->FindGeneratorTargetToUse(targetName);
if (tgt != nullptr) {
- this->Moc.Executable = SafeString(tgt->ImportedGetLocation(""));
+ this->Moc.Executable = tgt->ImportedGetLocation("");
} else {
err = "Could not find target " + targetName;
}
@@ -1329,7 +1324,7 @@ bool cmQtAutoGenInitializer::GetUicExecutable()
cmLocalGenerator* localGen = this->Target->GetLocalGenerator();
cmGeneratorTarget* tgt = localGen->FindGeneratorTargetToUse(targetName);
if (tgt != nullptr) {
- this->Uic.Executable = SafeString(tgt->ImportedGetLocation(""));
+ this->Uic.Executable = tgt->ImportedGetLocation("");
} else {
if (this->QtVersionMajor == "5") {
// Project does not use Qt5Widgets, but has AUTOUIC ON anyway
@@ -1394,7 +1389,7 @@ bool cmQtAutoGenInitializer::GetRccExecutable()
cmLocalGenerator* localGen = this->Target->GetLocalGenerator();
cmGeneratorTarget* tgt = localGen->FindGeneratorTargetToUse(targetName);
if (tgt != nullptr) {
- this->Rcc.Executable = SafeString(tgt->ImportedGetLocation(""));
+ this->Rcc.Executable = tgt->ImportedGetLocation("");
} else {
err = "Could not find target " + targetName;
}