summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/cmSystemTools.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx
index abe3ed6..3da646e 100644
--- a/Source/cmSystemTools.cxx
+++ b/Source/cmSystemTools.cxx
@@ -1322,6 +1322,10 @@ std::string cmSystemTools::MakeXMLSafe(const char* str)
}
}
}
+ if ( result.size() == 0 )
+ {
+ return "";
+ }
return std::string(&*result.begin(), result.size());
}