Skip to content

Commit

Permalink
Do not strip newlines from XML
Browse files Browse the repository at this point in the history
  • Loading branch information
melissalinkert committed Nov 2, 2012
1 parent 1d6e2ce commit 854d331
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion components/common/src/loci/common/xml/XMLTools.java
Expand Up @@ -183,7 +183,7 @@ public static String getXML(Document doc)
public static String sanitizeXML(String s) {
final char[] c = s.toCharArray();
for (int i=0; i<s.length(); i++) {
if (Character.isISOControl(c[i]) ||
if ((Character.isISOControl(c[i]) && !Character.isWhitespace(c[i])) ||
!Character.isDefined(c[i]))
{
c[i] = ' ';
Expand Down

0 comments on commit 854d331

Please sign in to comment.