Author: rfm
Date: Mon May 22 15:13:05 2017
New Revision: 40511
URL: http://svn.gna.org/viewcvs/gnustep?rev=40511&view=rev
Log:
escape formfeed in xml
Modified:
libs/webservices/trunk/GWSCoder.m
Modified: libs/webservices/trunk/GWSCoder.m
URL:
http://svn.gna.org/viewcvs/gnustep/libs/webservices/trunk/GWSCoder.m?rev=40511&r1=40510&r2=40511&view=diff
==============================================================================
--- libs/webservices/trunk/GWSCoder.m (original)
+++ libs/webservices/trunk/GWSCoder.m Mon May 22 15:13:05 2017
@@ -544,7 +544,7 @@
unichar c = from[i];
if ((c >= 0x20 && c <= 0xd7ff)
- || c == 0x9 || c == 0xd || c == 0xa
+ || c == 0x9 || c == 0xd || c == 0xc || c == 0xa
|| (c >= 0xe000 && c <= 0xfffd))
{
switch (c)
@@ -566,6 +566,7 @@
escape = YES;
break;
+ case '\f':
case '\r':
output += 5;
escape = YES;
@@ -607,7 +608,7 @@
unichar c = from[i];
if ((c >= 0x20 && c <= 0xd7ff)
- || c == 0x9 || c == 0xd || c == 0xa
+ || c == 0x9 || c == 0xd || c == 0xc || c == 0xa
|| (c >= 0xe000 && c <= 0xfffd))
{
switch (c)
@@ -649,6 +650,14 @@
to[j++] = '&';
to[j++] = 'g';
to[j++] = 't';
+ to[j++] = ';';
+ break;
+
+ case '\f':
+ to[j++] = '&';
+ to[j++] = '#';
+ to[j++] = '1';
+ to[j++] = '2';
to[j++] = ';';
break;
_______________________________________________
Gnustep-cvs mailing list
[email protected]
https://mail.gna.org/listinfo/gnustep-cvs