diff options
author | Brad King <brad.king@kitware.com> | 2014-06-24 17:05:08 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2014-06-24 17:05:08 (GMT) |
commit | 24853afa87f88a307f1d3c871a30661b812e83bc (patch) | |
tree | 6561368a513a5f4cca850065fb3450aa4a8e99ad /Source | |
parent | 8766f8ef4732e8dc4b2b585adddfda38ad23ea43 (diff) | |
parent | c491cb1eb4030d70e7a04bcda5021ebd0e5ca88d (diff) | |
download | CMake-24853afa87f88a307f1d3c871a30661b812e83bc.zip CMake-24853afa87f88a307f1d3c871a30661b812e83bc.tar.gz CMake-24853afa87f88a307f1d3c871a30661b812e83bc.tar.bz2 |
Merge topic 'stringapi-crash-cleanup'
c491cb1e Fix some generator crashes on undefined CMAKE_BUILD_TYPE
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmExtraCodeBlocksGenerator.cxx | 2 | ||||
-rw-r--r-- | Source/cmExtraEclipseCDT4Generator.cxx | 2 | ||||
-rw-r--r-- | Source/cmLocalGenerator.cxx | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/Source/cmExtraCodeBlocksGenerator.cxx b/Source/cmExtraCodeBlocksGenerator.cxx index 6f76dc4..56a6edb 100644 --- a/Source/cmExtraCodeBlocksGenerator.cxx +++ b/Source/cmExtraCodeBlocksGenerator.cxx @@ -574,7 +574,7 @@ void cmExtraCodeBlocksGenerator::AppendTarget(cmGeneratedFileStream& fout, } } - const char* buildType = makefile->GetDefinition("CMAKE_BUILD_TYPE"); + std::string buildType = makefile->GetSafeDefinition("CMAKE_BUILD_TYPE"); std::string location; if ( target->GetType()==cmTarget::OBJECT_LIBRARY) { diff --git a/Source/cmExtraEclipseCDT4Generator.cxx b/Source/cmExtraEclipseCDT4Generator.cxx index e23551e..1beb3fd 100644 --- a/Source/cmExtraEclipseCDT4Generator.cxx +++ b/Source/cmExtraEclipseCDT4Generator.cxx @@ -968,7 +968,7 @@ void cmExtraEclipseCDT4Generator::CreateCProjectFile() const continue; } std::vector<std::string> includeDirs; - const char *config = mf->GetDefinition("CMAKE_BUILD_TYPE"); + std::string config = mf->GetSafeDefinition("CMAKE_BUILD_TYPE"); (*it)->GetIncludeDirectories(includeDirs, l->second, "C", config); this->AppendIncludeDirectories(fout, includeDirs, emmited); } diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 8ae1157..abfc3ed 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -1861,7 +1861,7 @@ void cmLocalGenerator::OutputLinkLibraries(std::string& linkLibraries, ((useWatcomQuote) ? WATCOMQUOTE : SHELL); bool escapeAllowMakeVars = !forResponseFile; cmOStringStream fout; - const char* config = this->Makefile->GetDefinition("CMAKE_BUILD_TYPE"); + std::string config = this->Makefile->GetSafeDefinition("CMAKE_BUILD_TYPE"); cmComputeLinkInformation* pcli = tgt.Target->GetLinkInformation(config); if(!pcli) { |