After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 636002 - xmlcatalog --add discards id, prefer, xml:base attributes
xmlcatalog --add discards id, prefer, xml:base attributes
Status: RESOLVED OBSOLETE
Product: libxml2
Classification: Platform
Component: catalog
2.7.7
Other Linux
: Normal normal
: ---
Assigned To: Daniel Veillard
libxml QA maintainers
Depends on:
Blocks:
 
 
Reported: 2010-11-28 19:11 UTC by Ville Skyttä
Modified: 2021-07-05 13:21 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Ville Skyttä 2010-11-28 19:11:39 UTC
xmlcatalog --add discards several things from an existing catalog when adding stuff to it, thus potentially breaking it.

Example reproducer:

$ cat foo.xml
<?xml version="1.0"?>
<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd">
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog" prefer="system" id="meh" xml:base="file:///tmp/">
  <system id="idSystem" systemId="baz" uri="quux" xml:base="Ffffff" />
</catalog>
$ xmlcatalog --add system foo bar foo.xml
<?xml version="1.0"?>
<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd">
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
  <system systemId="baz" uri="quux"/>
  <system systemId="foo" uri="bar"/>
</catalog>

Notice how the original catalog/@prefer, catalog/@id, catalog/@xml:base, system/@id, and system/@xml:base have disappeared; they should have been kept as is.

(FWIW catalog/@id is not in the XML catalog 1.0 DTD, but is in the XML catalog 1.0 specification text.)
Comment 1 GNOME Infrastructure Team 2021-07-05 13:21:28 UTC
GNOME is going to shut down bugzilla.gnome.org in favor of gitlab.gnome.org.
As part of that, we are mass-closing older open tickets in bugzilla.gnome.org
which have not seen updates for a longer time (resources are unfortunately
quite limited so not every ticket can get handled).

If you can still reproduce the situation described in this ticket in a recent
and supported software version, then please follow
  https://wiki.gnome.org/GettingInTouch/BugReportingGuidelines
and create a new ticket at
  https://gitlab.gnome.org/GNOME/libxml2/-/issues/

Thank you for your understanding and your help.