diff options
Diffstat (limited to 'Source/CTest/cmCTestBuildHandler.cxx')
-rw-r--r-- | Source/CTest/cmCTestBuildHandler.cxx | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/Source/CTest/cmCTestBuildHandler.cxx b/Source/CTest/cmCTestBuildHandler.cxx index 7141daf..f96ef6d 100644 --- a/Source/CTest/cmCTestBuildHandler.cxx +++ b/Source/CTest/cmCTestBuildHandler.cxx @@ -92,7 +92,7 @@ static const char* cmCTestErrorMatches[] = { "^The project cannot be built\\.", "^\\[ERROR\\]", "^Command .* failed with exit code", - 0 + CM_NULLPTR }; static const char* cmCTestErrorExceptions[] = { @@ -107,7 +107,7 @@ static const char* cmCTestErrorExceptions[] = { ":[ \\t]+Where:", "([^ :]+):([0-9]+): Warning", "------ Build started: .* ------", - 0 + CM_NULLPTR }; static const char* cmCTestWarningMatches[] = { @@ -132,7 +132,7 @@ static const char* cmCTestWarningMatches[] = { "cc-[0-9]* CC: REMARK File = .*, Line = [0-9]*", "^CMake Warning.*:", "^\\[WARNING\\]", - 0 + CM_NULLPTR }; static const char* cmCTestWarningExceptions[] = { @@ -152,7 +152,7 @@ static const char* cmCTestWarningExceptions[] = { "ld32: WARNING 85: definition of dataKey in", "cc: warning 422: Unknown option \"\\+b", "_with_warning_C", - 0 + CM_NULLPTR }; struct cmCTestBuildCompileErrorWarningRex @@ -170,7 +170,7 @@ static cmCTestBuildCompileErrorWarningRex cmCTestWarningErrorFileLine[] = { { "^([a-zA-Z./0-9_+ ~-]+)\\(([0-9]+)\\)", 1, 2 }, { "\"([a-zA-Z./0-9_+ ~-]+)\", line ([0-9]+)", 1, 2 }, { "File = ([a-zA-Z./0-9_+ ~-]+), Line = ([0-9]+)", 1, 2 }, - { 0, 0, 0 } + { CM_NULLPTR, 0, 0 } }; cmCTestBuildHandler::cmCTestBuildHandler() @@ -521,7 +521,7 @@ public: { } FragmentCompare() - : FTC(0) + : FTC(CM_NULLPTR) { } bool operator()(std::string const& l, std::string const& r) @@ -790,7 +790,7 @@ int cmCTestBuildHandler::RunMakeCommand(const char* command, int* retVal, // First generate the command and arguments std::vector<std::string> args = cmSystemTools::ParseArguments(command); - if (args.size() < 1) { + if (args.empty()) { return false; } @@ -799,7 +799,7 @@ int cmCTestBuildHandler::RunMakeCommand(const char* command, int* retVal, a != args.end(); ++a) { argv.push_back(a->c_str()); } - argv.push_back(0); + argv.push_back(CM_NULLPTR); cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT, "Run command:", this->Quiet); @@ -851,7 +851,7 @@ int cmCTestBuildHandler::RunMakeCommand(const char* command, int* retVal, // For every chunk of data int res; - while ((res = cmsysProcess_WaitForData(cp, &data, &length, 0))) { + while ((res = cmsysProcess_WaitForData(cp, &data, &length, CM_NULLPTR))) { // Replace '\0' with '\n', since '\0' does not really make sense. This is // for Visual Studio output for (int cc = 0; cc < length; ++cc) { @@ -870,8 +870,9 @@ int cmCTestBuildHandler::RunMakeCommand(const char* command, int* retVal, } } - this->ProcessBuffer(0, 0, tick, tick_len, ofs, &this->BuildProcessingQueue); - this->ProcessBuffer(0, 0, tick, tick_len, ofs, + this->ProcessBuffer(CM_NULLPTR, 0, tick, tick_len, ofs, + &this->BuildProcessingQueue); + this->ProcessBuffer(CM_NULLPTR, 0, tick, tick_len, ofs, &this->BuildProcessingErrorQueue); cmCTestOptionalLog(this->CTest, HANDLER_PROGRESS_OUTPUT, " Size of output: " << ((this->BuildOutputLogSize + 512) / 1024) << "K" @@ -879,7 +880,7 @@ int cmCTestBuildHandler::RunMakeCommand(const char* command, int* retVal, this->Quiet); // Properly handle output of the build command - cmsysProcess_WaitForExit(cp, 0); + cmsysProcess_WaitForExit(cp, CM_NULLPTR); int result = cmsysProcess_GetState(cp); if (result == cmsysProcess_State_Exited) { |