You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by jy...@apache.org on 2004/11/02 15:53:47 UTC
cvs commit: xml-xalan/java/src/org/apache/xpath/axes DescendantIterator.java
jycli 2004/11/02 06:53:47
Modified: java/src/org/apache/xpath/axes DescendantIterator.java
Log:
String comparison should use String.equals(), instead of ==.
Even == works fine for most of the cases, for a serializable object, two variable originally reference to the same string
after deserialization, they no longer reference the same string, although the values are the same. Fix for bug XalanJ-1550
Revision Changes Path
1.24 +3 -3 xml-xalan/java/src/org/apache/xpath/axes/DescendantIterator.java
Index: DescendantIterator.java
===================================================================
RCS file: /home/cvs/xml-xalan/java/src/org/apache/xpath/axes/DescendantIterator.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- DescendantIterator.java 17 Aug 2004 19:25:34 -0000 1.23
+++ DescendantIterator.java 2 Nov 2004 14:53:47 -0000 1.24
@@ -271,8 +271,8 @@
// System.out.println("what: ");
// NodeTest.debugWhatToShow(what);
if(DTMFilter.SHOW_ALL == what
- || localName == NodeTest.WILD
- || namespace == NodeTest.WILD)
+ || NodeTest.WILD.equals(localName)
+ || NodeTest.WILD.equals(namespace))
{
m_extendedTypeID = 0;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-cvs-help@xml.apache.org