Commit d843a2fc authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Avoid char conversion in strchr() - should fix #6266

parent b3cd3651
......@@ -422,7 +422,7 @@ char *convert_xml_special_chars (const char *str)
}
if ((cp & ~0x0080) < 32 /* C0/C1 control codes */
&& strchr ("\x09\x0A\x0D\x85", cp) == NULL)
&& memchr ("\x09\x0A\x0D\x85", cp, 4) == NULL)
ptr += sprintf (ptr, "&#%"PRIu32";", cp);
else
switch (cp)
......
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