summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/cmCTest.cxx8
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx
index 150fdf5..e3571b1 100644
--- a/Source/cmCTest.cxx
+++ b/Source/cmCTest.cxx
@@ -472,8 +472,12 @@ int cmCTest::UpdateDirectory()
<< "\t<BuildStamp>" << m_CurrentTag << "-Experimental</BuildStamp>\n"
<< "\t<StartDateTime>" << start_time << "</StartDateTime>\n"
<< "\t<UpdateCommand>" << command << "</UpdateCommand>\n"
- << "\t<UpdateReturnStatus>" << retVal
- << "</UpdateReturnStatus>" << std::endl;
+ << "\t<UpdateReturnStatus>";
+ if ( retVal )
+ {
+ os << retVal;
+ }
+ os << "</UpdateReturnStatus>" << std::endl;
std::vector<cmStdString> lines;
cmSystemTools::Split(output.c_str(), lines);