Re: [xml] empty CDATA sections

On Mon, Mar 03, 2008 at 09:45:18AM -0800, Darin Adler wrote:
Hi folks.

As you may know, WebKit currently uses libxml2 to handle XML  
documents, including XHTML. I recently discovered that a number of Ian  
Hickson's test cases that work fine in other browsers fail in browsers  
based on WebKit. That's because libxml2 discards empty CDATA sections.  
I filed this bug:

And Mark Rowe attached a patch that resolves the issue.

Daniel pointed out that some clients of libxml2 may be depending on  
the current behavior; some may see this as a feature rather than a bug.

Does anyone have any comments, objections to this change perhaps or  
support for the change?

  One of the things which should probably be reviewed is the impact
when doing XPath/XSLT, i.e. check that with the settings needed to build
an XPath tree we don't end up with extra text nodes which would break
XPath adressing, and probably check also the impact when doing type
validation, i.e. how an empty CDATA added in an element content should
affect (or not) XSD/RelaxNG. That mean at least a few tests to be added
to libxml2 regression test suite.


Red Hat Virtualization group
Daniel Veillard      | virtualization library
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]