This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 92731

Summary: XDMUtil does not handle default namespace properly
Product: xml Reporter: Alexander Fung <afung>
Component: XDMAssignee: issues@xml <issues>
Status: RESOLVED FIXED    
Severity: blocker    
Priority: P2    
Version: 5.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Alexander Fung 2007-01-17 19:17:50 UTC
In using the XDMUtil class to compare two XML fragments, it's failing on empty 
namespace declarations.  The empty namespace declarations shouldn't be causing 
a difference in this case (see http://www.w3.org/TR/2006/REC-xml-names-
20060816/#defaulting).

XML Document 1:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ 
http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
  <result xmlns="">
    <string xmlns="urn:BindingsCombinationTest">b1</string>
    <nonNegativeInteger 
xmlns="urn:BindingsCombinationTest">100</nonNegativeInteger>
    <byte xmlns="urn:BindingsCombinationTest">a</byte>
    <short xmlns="urn:BindingsCombinationTest">5</short>
    <int xmlns="urn:BindingsCombinationTest">12345</int>
    <long xmlns="urn:BindingsCombinationTest">12345</long>
    <negativeInteger xmlns="urn:BindingsCombinationTest">-100</negativeInteger>
    <dateTime xmlns="urn:BindingsCombinationTest">10/10/2000</dateTime>
    <nonPositiveInteger 
xmlns="urn:BindingsCombinationTest">0</nonPositiveInteger>
    <duration xmlns="urn:BindingsCombinationTest">P0Y0M0DT0H0M10S</duration>
    <ENTITIES xmlns="urn:BindingsCombinationTest">string byte short</ENTITIES>
    <double xmlns="urn:BindingsCombinationTest">1.111</double>
    <ENTITY xmlns="urn:BindingsCombinationTest">byte</ENTITY>
    <float xmlns="urn:BindingsCombinationTest">1.11</float>
  </result>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
 
XML Document 2:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ 
http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
  <result>
    <string xmlns="urn:BindingsCombinationTest">b1</string>
    <nonNegativeInteger 
xmlns="urn:BindingsCombinationTest">100</nonNegativeInteger>
    <byte xmlns="urn:BindingsCombinationTest">a</byte>
    <short xmlns="urn:BindingsCombinationTest">5</short>
    <int xmlns="urn:BindingsCombinationTest">12345</int>
    <long xmlns="urn:BindingsCombinationTest">12345</long>
    <negativeInteger xmlns="urn:BindingsCombinationTest">-100</negativeInteger>
    <dateTime xmlns="urn:BindingsCombinationTest">10/10/2000</dateTime>
    <nonPositiveInteger 
xmlns="urn:BindingsCombinationTest">0</nonPositiveInteger>
    <duration xmlns="urn:BindingsCombinationTest">P0Y0M0DT0H0M10S</duration>
    <ENTITIES xmlns="urn:BindingsCombinationTest">string byte short</ENTITIES>
    <double xmlns="urn:BindingsCombinationTest">1.111</double>
    <ENTITY xmlns="urn:BindingsCombinationTest">byte</ENTITY>
    <float xmlns="urn:BindingsCombinationTest">1.11</float>
  </result>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
Comment 1 Ayub Khan 2007-01-17 23:12:54 UTC
Fix checked into release551 branch

File Diffs
===========

/cvs/xml/xdm/test/unit/src/org/netbeans/modules/xml/xdm/diff/Attic/xdmutil1.xml
new revision: 1.1.2.1; previous revision: 1.1

/cvs/xml/xdm/test/unit/src/org/netbeans/modules/xml/xdm/diff/Attic/xdmutil2.xml
new revision: 1.1.2.1; previous revision: 1.1

/cvs/xml/xdm/test/unit/src/org/netbeans/modules/xml/xdm/diff/XDMUtilTest.java
new revision: 1.1.2.3.6.1; previous revision: 1.1.2.3

/cvs/xml/xdm/src/org/netbeans/modules/xml/xdm/diff/XDMUtil.java  
new revision: 1.1.2.2.6.1; previous revision: 1.1.2.2


Comment 2 tonybeckham 2007-04-11 23:37:11 UTC
afung:
This issue submitted by you is marked as resolved. Since it relates to some
source code specifics, QA is unable to verify it. Could you please verify this
issue and mark it as verified or reopen it?