diff options
Diffstat (limited to 'Source/CTest')
-rw-r--r-- | Source/CTest/cmCTestBuildAndTestHandler.cxx | 9 | ||||
-rw-r--r-- | Source/CTest/cmCTestScriptHandler.cxx | 11 |
2 files changed, 11 insertions, 9 deletions
diff --git a/Source/CTest/cmCTestBuildAndTestHandler.cxx b/Source/CTest/cmCTestBuildAndTestHandler.cxx index 3856569..696b52f 100644 --- a/Source/CTest/cmCTestBuildAndTestHandler.cxx +++ b/Source/CTest/cmCTestBuildAndTestHandler.cxx @@ -126,10 +126,11 @@ public: cmSystemTools::SetStdoutCallback([&s](std::string const& m) { s += m; }); cmSystemTools::SetStderrCallback([&s](std::string const& m) { s += m; }); - this->CM.SetProgressCallback([&s](const char* msg, float /*unused*/) { - s += msg; - s += "\n"; - }); + this->CM.SetProgressCallback( + [&s](const std::string& msg, float /*unused*/) { + s += msg; + s += "\n"; + }); } ~cmCTestBuildAndTestCaptureRAII() diff --git a/Source/CTest/cmCTestScriptHandler.cxx b/Source/CTest/cmCTestScriptHandler.cxx index 2cbdc4e..a714abe 100644 --- a/Source/CTest/cmCTestScriptHandler.cxx +++ b/Source/CTest/cmCTestScriptHandler.cxx @@ -288,11 +288,12 @@ void cmCTestScriptHandler::CreateCMake() this->ParentMakefile->GetRecursionDepth()); } - this->CMake->SetProgressCallback([this](const char* m, float /*unused*/) { - if (m && *m) { - cmCTestLog(this->CTest, HANDLER_OUTPUT, "-- " << m << std::endl); - } - }); + this->CMake->SetProgressCallback( + [this](const std::string& m, float /*unused*/) { + if (!m.empty()) { + cmCTestLog(this->CTest, HANDLER_OUTPUT, "-- " << m << std::endl); + } + }); this->AddCTestCommand("ctest_build", new cmCTestBuildCommand); this->AddCTestCommand("ctest_configure", new cmCTestConfigureCommand); |