Bug 1038982

Summary: error parsing xml tree in a file
Product: Red Hat Enterprise Linux 6 Reporter: liste.ing-dpn
Component: libxml2Assignee: Daniel Veillard <veillard>
Status: CLOSED WONTFIX QA Contact: qe-baseos-tools-bugs
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.3CC: liste.ing-dpn
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-12-06 10:19:10 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description liste.ing-dpn 2013-12-06 09:51:04 UTC
Description of problem:
Parsing a xml tree in a file ends up with a error after I updated to libxml2-2.7.6-12 and libxml2-2.7.6-14.
The parsing don't give any errors on libxml2-2.7.6-4.

Version-Release number of selected component (if applicable):
libxml2-2.7.6-12
libxml2-2.7.6-14

no bug with libxml2-2.7.6-4

How reproducible:
reproducible everytime.

Steps to Reproduce:
1.
>>> from io import BytesIO
>>> from lxml import etree
>>> xml='''<root>
... <child name='one' />
... <child name='two' />
... </root>
... '''
>>> document = etree.iterparse(BytesIO(xml), events=('end',), tag='root')
>>> for action, elem in document:
... print("%s: %s" % (action, elem.tag))
...
end: root
>>> file('/tmp/test.xml', 'w').write(xml)
>>> document = etree.iterparse('/tmp/test.xml', events=('end',), tag='root')
>>> for action, elem in document:
... print("%s: %s" % (action, elem.tag))
...
end: root
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
    File "iterparse.pxi", line 478, in lxml.etree.iterparse.__next__ (src/lxml/lxml.etree.c:98432)
      File "iterparse.pxi", line 530, in lxml.etree.iterparse._read_more_events (src/lxml/lxml.etree.c:98953)
        File "parser.pxi", line 601, in lxml.etree._raiseParseError (src/lxml/lxml.etree.c:74863)
	lxml.etree.XMLSyntaxError: None

Actual results:
The parsing fails. It actually works again when I downgraded to libxml2-2.7.6-4.

Expected results:
Parsing shouldn't return an error (as in previous version of libxml2).

Additional info:
The bug has been reported and fixed on ubuntu bug tracker : https://bugs.launchpad.net/ubuntu/+source/libxml2/+bug/1201849

Comment 2 Jan Kurik 2017-12-06 10:19:10 UTC
Red Hat Enterprise Linux 6 is in the Production 3 Phase. During the Production 3 Phase, Critical impact Security Advisories (RHSAs) and selected Urgent Priority Bug Fix Advisories (RHBAs) may be released as they become available.

The official life cycle policy can be reviewed here:

http://redhat.com/rhel/lifecycle

This issue does not meet the inclusion criteria for the Production 3 Phase and will be marked as CLOSED/WONTFIX. If this remains a critical requirement, please contact Red Hat Customer Support to request a re-evaluation of the issue, citing a clear business justification. Note that a strong business justification will be required for re-evaluation. Red Hat Customer Support can be contacted via the Red Hat Customer Portal at the following URL:

https://access.redhat.com/