summaryrefslogtreecommitdiffstats
path: root/save-xml.c
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2012-08-27 13:07:47 -0700
committerGravatar Linus Torvalds <torvalds@linux-foundation.org>2012-08-27 13:07:47 -0700
commit0640af873bcce6db0119bac5f0fe29e89cd6f04b (patch)
tree2ea129fd7077a6180c9d36d1c4cc7c39803af7ec /save-xml.c
parent36fc771c9b96f8cdd8454657b5444ceb66eaa0a6 (diff)
parent162b69828aa374f0bec24db58b05100afcb51b9a (diff)
downloadsubsurface-0640af873bcce6db0119bac5f0fe29e89cd6f04b.tar.gz
Merge branch 'quoting' of git://git.hohndel.org/subsurface
Pull xml quoting fix from Dirk Hohndel. * 'quoting' of git://git.hohndel.org/subsurface: Add single and double quotes to escaped characters in XML output
Diffstat (limited to 'save-xml.c')
-rw-r--r--save-xml.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/save-xml.c b/save-xml.c
index 37d6d062e..6b08c9511 100644
--- a/save-xml.c
+++ b/save-xml.c
@@ -97,6 +97,12 @@ static void quote(FILE *f, const char *text)
case '&':
escape = "&amp;";
break;
+ case '\'':
+ escape = "&apos;";
+ break;
+ case '\"':
+ escape = "&quot;";
+ break;
}
fwrite(text, (p - text - 1), 1, f);
if (!escape)