diff options
Diffstat (limited to 'Source/cmSystemTools.cxx')
-rw-r--r-- | Source/cmSystemTools.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index de181f0..c05238a 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -321,6 +321,19 @@ std::string cmSystemTools::EscapeSpaces(const char* str) #endif } +std::string cmSystemTools::EscapeQuotes(const char* str) +{ + std::string result = ""; + for(const char* ch = str; *ch != '\0'; ++ch) + { + if(*ch == '"') + { + result += '\\'; + } + result += *ch; + } + return result; +} // return true if the file exists bool cmSystemTools::FileExists(const char* filename) |