Bug #72181 [Com]: XML Reader - Parser error on valid XML
| From: | ptrktck at gmail dot com | Date: | Tue, 17 Jan 2017 12:48:03 +0000 |
| Subject: | Bug #72181 [Com]: XML Reader - Parser error on valid XML | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-206709@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=72181&edit=1
ID: 72181
Comment by: ptrktck at gmail dot com
Reported by: alanhmlam at gmail dot com
Summary: XML Reader - Parser error on valid XML
Status: No Feedback
Type: Bug
Package: XML Reader
Operating System: Windows Server 2008
PHP Version: 7.0.6
Block user comment: N
Private report: N
New Comment:
reproduced on 7.0.13-0ubuntu0.16.04.1
works properly on 7.0.12-1+deb.sury.org~trusty+1
not sure if different ppa's matter here
Previous Comments:
------------------------------------------------------------------------
[2016-09-02 20:32:05] requinix@php.net
I cannot reproduce on 7.0.9.
@webtota: please check that the given XML and code works for you, then create a new report for your
bug.
------------------------------------------------------------------------
[2016-09-02 15:25:33] webtota at gmail dot com
still reproducible on 7.0.8
------------------------------------------------------------------------
[2016-05-22 04:22:22] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
------------------------------------------------------------------------
[2016-05-09 16:18:58] ab@php.net
Thanks for the report. It looks very similar to the bug #71805 which is caused by a libxml
regression. This should be fixed in the 7.0.7RC1. Please check, it'll be out this week.
Thanks.
------------------------------------------------------------------------
[2016-05-09 16:11:23] alanhmlam at gmail dot com
Description:
------------
valid.xml: https://al2k4.s-ul.eu/BGiN0kKt
Reverting back to 7.0.2 will cause XML Reader to read the XML properly.
Version 7.0.3 or higher will cause XML Reader to throw "Input is not proper UTF-8".
Test script:
---------------
<?php
$reader = new XMLReader();
$reader->open("valid.xml");
while($reader->read()) {
}
?>
Expected result:
----------------
No output.
Actual result:
--------------
PHP Warning: XMLReader::read(): file:/C:/Test/valid.xml:6: parser error : Input is not proper
UTF-8, indicate encoding !
Bytes: 0xE2 0x80 0x93 0x20 in C:\Test\test.php on line 5
Warning: XMLReader::read(): file:/C:/Test/valid.xml:6: parser error : Input is not proper UTF-8,
indicate encoding !
Bytes: 0xE2 0x80 0x93 0x20 in C:\Test\test.php on line 5
PHP Warning: XMLReader::read(): f the train station. Open day to be held on Saturday 21st November
between 10am in C:\Test\test.php on line 5
Warning: XMLReader::read(): f the train station. Open day to be held on Saturday 21st November
between 10am in C:\Test\test.php on line 5
PHP Warning: XMLReader::read():
^ in C:\Test\test.php on line 5
Warning: XMLReader::read():
^ in C:\Test\test.php on line 5
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=72181&edit=1