Re: [PATCH] ext/xml/compat.c fix for #32001
| From: | Rob Richards | Date: | Thu, 17 Feb 2005 12:19:46 +0000 |
| Subject: | Re: [PATCH] ext/xml/compat.c fix for #32001 | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-15045@lists.php.net to get a copy of this message | ||
It looks like there would be BC breaks unless libxml with the bug fix is used as the encoding is detected properly and no infinite loop if an xml declaration or BOM is used in the xml. So basically with the patch there is no more autodetecting if used with any other libxml versions (though no more possibilities of inifinte loops).
i.e.
$simple = "<?xml version='1.0'?><para><note>simple note</note></para>";
$simple = "\xEF\xBB\xBF<para><note>simple note</note></para>";
These both currently work without going into an infinite loop.
Rob
Christian Stocker wrote:
Any BC breaks with that? Do I have to know now the encoding of the XML document, before I can use the push parser? But reading your bugreport at gnome.org, I assume it just defaults to UTF-8, right?