
The & symbol isn't escaped at all. As a result, "normal" XML parsing fails.
Moderator: NADEO
Code: Select all
protected function parseXMLstring()
{
[...]
// escape '&' characters unless already a known entity
$xml = preg_replace('/&(?!(?:amp|quot|apos|lt|gt);)/', '&', $this->xml);
[...]
}
They're actually not as you can notice in Xymph's regex (lt and gt are respectively < and >)TGYoshi wrote:I suspect (or hope) < and > are escaped properly, so why not make sure & is escaped as well?
Doesn't it search for & without a lt/gt/.. behind it, then replace it?The_Big_Boo wrote:They're actually not as you can notice in Xymph's regex (lt and gt are respectively < and >)TGYoshi wrote:I suspect (or hope) < and > are escaped properly, so why not make sure & is escaped as well?
Yes. The problem is that of course we can expect it to be corrected one day, but anyway to support existing replays you are anyway forced to handle it like it is actually (and so don't really care if it is corrected or not)TGYoshi wrote:So I suspect < and > is escaped, but & isn't for some stupid reason.
Users browsing this forum: No registered users and 1 guest