diff options
Diffstat (limited to 'Source/cmCommand.cxx')
-rw-r--r-- | Source/cmCommand.cxx | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/Source/cmCommand.cxx b/Source/cmCommand.cxx index d349c91..99bdd1e 100644 --- a/Source/cmCommand.cxx +++ b/Source/cmCommand.cxx @@ -2,11 +2,17 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmCommand.h" +#include "cmExecutionStatus.h" #include "cmMakefile.h" -class cmExecutionStatus; struct cmListFileArgument; +void cmCommand::SetExecutionStatus(cmExecutionStatus* status) +{ + this->Status = status; + this->Makefile = &status->GetMakefile(); +} + bool cmCommand::InvokeInitialPass(const std::vector<cmListFileArgument>& args, cmExecutionStatus& status) { @@ -19,15 +25,7 @@ bool cmCommand::InvokeInitialPass(const std::vector<cmListFileArgument>& args, return this->InitialPass(expandedArguments, status); } -const char* cmCommand::GetError() -{ - if (this->Error.empty()) { - return "unknown error."; - } - return this->Error.c_str(); -} - void cmCommand::SetError(const std::string& e) { - this->Error = e; + this->Status->SetError(e); } |