From d18c8d6ad7a9111f4fec515ae58096da744f3d61 Mon Sep 17 00:00:00 2001 From: Alex Neundorf Date: Tue, 21 Dec 2010 21:59:39 +0100 Subject: Fix crash in Eclipse generator with empty project (#11616) If there was no language at all enabled, CMAKE_BUILD_TYPE was empty, which was not expected, and made the generator crash. Alex --- Source/cmExtraEclipseCDT4Generator.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/cmExtraEclipseCDT4Generator.cxx b/Source/cmExtraEclipseCDT4Generator.cxx index 502fefa..0ef771f 100644 --- a/Source/cmExtraEclipseCDT4Generator.cxx +++ b/Source/cmExtraEclipseCDT4Generator.cxx @@ -201,7 +201,7 @@ void cmExtraEclipseCDT4Generator::CreateProjectFile() "\n" "\t" << this->GenerateProjectName(mf->GetProjectName(), - mf->GetDefinition("CMAKE_BUILD_TYPE"), + mf->GetSafeDefinition("CMAKE_BUILD_TYPE"), this->GetPathBasename(this->HomeOutputDirectory)) << "\n" "\t\n" -- cgit v0.12