summaryrefslogtreecommitdiff
path: root/cpp/src/Slice/Preprocessor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/Slice/Preprocessor.cpp')
-rw-r--r--cpp/src/Slice/Preprocessor.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/cpp/src/Slice/Preprocessor.cpp b/cpp/src/Slice/Preprocessor.cpp
index 832f0ae5756..c4ec27452e3 100644
--- a/cpp/src/Slice/Preprocessor.cpp
+++ b/cpp/src/Slice/Preprocessor.cpp
@@ -173,6 +173,14 @@ Slice::Preprocessor::preprocess(bool keepComments)
for(vector<string>::const_iterator i = messages.begin(); i != messages.end(); ++i)
{
emitRaw(i->c_str());
+
+ //
+ // MCPP FIX: mcpp does not always return non-zero exit status when there is an error.
+ //
+ if(i->find("error:") != string::npos)
+ {
+ status = 1;
+ }
}
}