mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-12 19:02:06 +01:00
do not escape for XML characters encoded with unicode equivalents
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@2111 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
d26301a65c
commit
8264ebdfb5
1 changed files with 10 additions and 2 deletions
|
@ -200,9 +200,17 @@ public class StringUtils {
|
|||
if (i > last) {
|
||||
out.append(input, last, i - last);
|
||||
}
|
||||
// Do nothing if the string is of the form ë (unicode value)
|
||||
if (!(len > i + 5
|
||||
&& input[i + 1] == '#'
|
||||
&& Character.isDigit(input[i + 2])
|
||||
&& Character.isDigit(input[i + 3])
|
||||
&& Character.isDigit(input[i + 4])
|
||||
&& input[i + 5] == ';')) {
|
||||
last = i + 1;
|
||||
out.append(AMP_ENCODE);
|
||||
}
|
||||
}
|
||||
else if (ch == '"') {
|
||||
if (i > last) {
|
||||
out.append(input, last, i - last);
|
||||
|
|
Loading…
Reference in a new issue