You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by "Alberto Massari (JIRA)" <xe...@xml.apache.org> on 2005/03/08 10:42:52 UTC
[jira] Resolved: (XERCESC-1371) DOMWriter fails to emit default namespace under some circumstances
[ http://issues.apache.org/jira/browse/XERCESC-1371?page=history ]
Alberto Massari resolved XERCESC-1371:
--------------------------------------
Resolution: Fixed
A fix is in CVS. Please verify.
Alberto
> DOMWriter fails to emit default namespace under some circumstances
> ------------------------------------------------------------------
>
> Key: XERCESC-1371
> URL: http://issues.apache.org/jira/browse/XERCESC-1371
> Project: Xerces-C++
> Type: Bug
> Components: DOM
> Versions: 2.5.0, 2.6.0
> Environment: Visual Studio .NET 2003 on Windows XP
> Reporter: Jesse Pelton
> Attachments: CreateDOMDocument.cpp
>
> I've modified the CreateDOMDocument sample to use createElementNS() rather than createElement() to create and serialize a document like the following:
> <?xml version="1.0" encoding="UTF-8" standalone="no" ?>
> <company xmlns="NSOne">
> <product xmlns="NSTwo">Xerces-C
> <foo xmlns="NSOne"/>
> </product>
> <category idea="great">XML Parsing Tools</category>
> <developedBy>Apache Software Foundation</developedBy>
> </company>
> DOMWriter omits the namespace from the "foo" element, so the program emits the following (some blank lines removed):
> <?xml version="1.0" encoding="UTF-8" standalone="no" ?>
> <company xmlns="NSOne">
> <product xmlns="NSTwo">Xerces-C
> <foo/>
> </product>
> <category idea="great">XML Parsing Tools</category>
> <developedBy>Apache Software Foundation</developedBy>
> </company>
> The problem appears to occur when an element's default namespace URI is also used by an ancestor, but an intervening ancestor has a different default namespace URI.
> I suspect that versions 2.3 and 2.4 are also affected.
> I'll attach the modified sample.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org