[xml/sgml-pkgs] Bug#862322: Bug#862322: [libxml2] Wrong warning/error about "colons are forbidden from PI names"

Mattia Rizzolo mattia at debian.org
Thu May 11 09:40:13 UTC 2017


Control: tag -1 upstream

On Thu, May 11, 2017 at 10:44:54AM +0200, Andre Naujoks wrote:
> When parsing an XML Document, libxml2 wrongly reports an error
> (seemingly without further consequences) about colons not being allowed
> in Processing-Instruction names.
> 
> This is not true. The XML Specification
> (https://www.w3.org/TR/REC-xml/#sec-pi and
> https://www.w3.org/TR/REC-xml/#NT-Name) explicitly allows a colon (':')
> as part of a PITarget, which is a Name in the XML specifications terms.
> The last Version of the XML Specification, where a colon was not allowed
> in a processing instruction name is over 20 years old and I think can be
> safely ignored by now: https://www.w3.org/TR/WD-xml-lang-970331#NT-Name
> 
> Attached is a test document (test.xml), which triggers the warning, when
> used for example with xmlstarlet like this:
> 
> Also attached is a patch (libxml2_patch_colons_in_pinames.patch), that
> removes the bit of code from libxml2, that triggers the message.
> 
> I am not sure about the side effects of the removed function-call, but
> from the comments in the code it seems it should have aborted
> processing. It specifically states for xmlNsErr: "Handle a fatal parser
> error, i.e. violating Well-Formedness constraints". However it does not
> really abort, which might warrant another bug report.

Please, could you file this bug upstream?
We don't want to include patches that are not upstream, exactly because
there might very well be side effects otherwise not clear.
Here is where:
https://bugzilla.gnome.org/buglist.cgi?product=libxml2
https://bugzilla.gnome.org/enter_bug.cgi?product=libxml2

-- 
regards,
                        Mattia Rizzolo

GPG Key: 66AE 2B4A FCCF 3F52 DA18  4D18 4B04 3FCD B944 4540      .''`.
more about me:  https://mapreri.org                             : :'  :
Launchpad user: https://launchpad.net/~mapreri                  `. `'`
Debian QA page: https://qa.debian.org/developer.php?login=mattia  `-
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/debian-xml-sgml-pkgs/attachments/20170511/5b29b42d/attachment.sig>


More information about the debian-xml-sgml-pkgs mailing list