summaryrefslogtreecommitdiff
path: root/Source/CTest/cmCTestConfigureCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/CTest/cmCTestConfigureCommand.cxx')
-rw-r--r--Source/CTest/cmCTestConfigureCommand.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/Source/CTest/cmCTestConfigureCommand.cxx b/Source/CTest/cmCTestConfigureCommand.cxx
index f2f42b4f2d..3854710819 100644
--- a/Source/CTest/cmCTestConfigureCommand.cxx
+++ b/Source/CTest/cmCTestConfigureCommand.cxx
@@ -69,12 +69,11 @@ cmCTestGenericHandler* cmCTestConfigureCommand::InitializeHandler()
bool multiConfig = false;
bool cmakeBuildTypeInOptions = false;
- cmGlobalGenerator* gg =
- this->Makefile->GetCMakeInstance()->CreateGlobalGenerator(
- cmakeGeneratorName);
+ auto gg = this->Makefile->GetCMakeInstance()->CreateGlobalGenerator(
+ cmakeGeneratorName);
if (gg) {
multiConfig = gg->IsMultiConfig();
- delete gg;
+ gg.reset();
}
std::string cmakeConfigureCommand =