summaryrefslogtreecommitdiffstats
path: root/Source/cmMessageCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmMessageCommand.cxx')
-rw-r--r--Source/cmMessageCommand.cxx20
1 files changed, 16 insertions, 4 deletions
diff --git a/Source/cmMessageCommand.cxx b/Source/cmMessageCommand.cxx
index c6e8e16..e1722be 100644
--- a/Source/cmMessageCommand.cxx
+++ b/Source/cmMessageCommand.cxx
@@ -28,6 +28,7 @@ bool cmMessageCommand::InitialPass(std::vector<std::string> const& args)
std::vector<std::string>::const_iterator i = args.begin();
bool send_error = false;
+ bool fatal_error = false;
bool status = false;
if (*i == "SEND_ERROR")
{
@@ -36,11 +37,19 @@ bool cmMessageCommand::InitialPass(std::vector<std::string> const& args)
}
else
{
- if (*i == "STATUS")
+ if (*i == "STATUS")
+ {
+ status = true;
+ ++i;
+ }
+ else
+ {
+ if (*i == "FATAL_ERROR")
{
- status = true;
- ++i;
+ fatal_error = true;
+ ++i;
}
+ }
}
for(;i != args.end(); ++i)
@@ -63,7 +72,10 @@ bool cmMessageCommand::InitialPass(std::vector<std::string> const& args)
cmSystemTools::Message(message.c_str());
}
}
-
+ if(fatal_error)
+ {
+ cmSystemTools::SetFatalErrorOccured();
+ }
return true;
}