sandygao 2002/10/17 19:22:05
Modified: java/src/org/apache/xerces/util NamespaceSupport.java
Log:
Making sure that getPrefix() returns the correct prefix. In the following case:
<e1 xmlns:p="uri1"> <e2 xmlns:p="uri2"> ... </e2> </e1>
In the context of "e2", getPrefix("uri1") shouldn't return "p".
Revision Changes Path
1.13 +3 -2 xml-xerces/java/src/org/apache/xerces/util/NamespaceSupport.java
Index: NamespaceSupport.java
===================================================================
RCS file:
/home/cvs/xml-xerces/java/src/org/apache/xerces/util/NamespaceSupport.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- NamespaceSupport.java 14 Aug 2002 22:51:08 -0000 1.12
+++ NamespaceSupport.java 18 Oct 2002 02:22:05 -0000 1.13
@@ -316,7 +316,8 @@
// find uri in current context
for (int i = fNamespaceSize; i > 0; i -= 2) {
if (fNamespace[i - 1] == uri) {
- return fNamespace[i - 2];
+ if (getURI(fNamespace[i - 2]) == uri)
+ return fNamespace[i - 2];
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]