Bug #71805 [Opn->Ver]: XML files can generate UTF-8 error even if they are UTF-8

From: Date: Mon, 14 Mar 2016 15:01:59 +0000
Subject: Bug #71805 [Opn->Ver]: 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-199819@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 Updated by: ab@php.net Reported by: goozak at gmail dot com Summary: XML files can generate UTF-8 error even if they are UTF-8 -Status: Open +Status: Verified Type: Bug Package: XML Reader Operating System: Win7 SP1 PHP Version: 5.5Git-2016-03-11 (snap) -Assigned To: +Assigned To: ab Block user comment: N Private report: N New Comment: 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. Previous Comments: ------------------------------------------------------------------------ [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

« previous php.bugs (#199819) next »