Commit d805ec15 authored by Sergey Toshin's avatar Sergey Toshin

Adds more escape for unreadable characters so parser won't throw exceptions during parse

parent d5cfdfb5
......@@ -149,6 +149,9 @@ public class StringUtils {
}
private static String escapeXmlChar(char c) {
if(c >= 0 && c <= 0x1F) {
return "\\" + (int) c;
}
switch (c) {
case '&':
return "&amp;";
......@@ -160,6 +163,8 @@ public class StringUtils {
return "&quot;";
case '\'':
return "&apos;";
case '\\':
return "\\\\";
default:
return null;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment