Bug #71805 [Com]: XML files can generate UTF-8 error even if they are UTF-8
| From: | goozak at gmail dot com | Date: | Tue, 03 May 2016 18:24:01 +0000 |
| Subject: | Bug #71805 [Com]: XML files can generate UTF-8 error even if they are UTF-8 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-200880@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=71805&edit=1
ID: 71805
Comment by: goozak at gmail dot com
Reported by: goozak at gmail dot com
Summary: XML files can generate UTF-8 error even if they are
UTF-8
Status: Feedback
Type: Bug
Package: XML Reader
Operating System: Win7 SP1
PHP Version: 5.5Git-2016-03-11 (snap)
Assigned To: ab
Block user comment: N
Private report: N
New Comment:
I'm on Windows, so I'll check the 5.6 RC when available. The 5.5 one seems stuck on
5.5.27RC1 (2015-Jun-24) http://windows.php.net/qa/
Previous Comments:
------------------------------------------------------------------------
[2016-05-03 16:10:26] ab@php.net
Dependency packages are upgraded. Please check the upcoming RCs.
Thanks.
------------------------------------------------------------------------
[2016-03-14 15:01:58] ab@php.net
Thanks for the report. Looks like we see a regression in libxml 2.9.3, see https://bugzilla.gnome.org/show_bug.cgi?id=760183
. No fix to this is currently available in the libxml2 repo. I'll keep an eye and will apply
this patch to our dependency base as soon as it's available.
Thanks.
------------------------------------------------------------------------
[2016-03-11 21:22:51] goozak at gmail dot com
Description:
------------
XML Reader generate error
"Warning: XMLReader::readOuterXml(): .....:5: parser error : Input is not proper UTF-8,
indicate encoding ! Bytes: 0xC3 0xA9 0x78 0x20"
even though the file is properly encoded in UTF-8.
A small change to the XML content can be made (remove a tag or even just some characters) and the
file is then read properly.
Test script:
---------------
https://gist.github.com/goozak/aa3f5bd5a146a51ddd75
Two files are used in the demo. Result will be the same if they are downloaded locally.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=71805&edit=1