You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Sam Ruby <ru...@us.ibm.com> on 2001/08/11 14:39:48 UTC
Xerces-j regression: NullPointerException in nextMatchingElementAfter
stack traceback:
java.lang.NullPointerException
at org.apache.xerces.dom.DeepNodeListImpl.nextMatchingElementAfter(Unknown Source)
at org.apache.xerces.dom.DeepNodeListImpl.item(Unknown Source)
at org.apache.xerces.dom.DeepNodeListImpl.getLength(Unknown Source)
at testcase.main(testcase.java:12)
Exception in thread "main"
testcase.java:
import javax.xml.parsers.*;
import org.w3c.dom.*;
public class testcase {
public static void main(String[] args) throws Exception {
DocumentBuilderFactory dFactory = DocumentBuilderFactory.newInstance();
DocumentBuilder dBuilder = dFactory.newDocumentBuilder();
Document document = dBuilder.parse(new java.io.File(args[0]));
Element element = document.getDocumentElement();
NodeList nodelist = element.getElementsByTagName("element");
if (nodelist != null) System.out.println(nodelist.getLength());
}
}
testdata.xml:
<document><element/></document>
I've isolated the problem to the commit that occurred at
Fri Aug 10 01:18:16 2001 UTC by lehors
- Sam Ruby
Re: Xerces-j regression: NullPointerException in
nextMatchingElementAfter
Posted by Arnaud Le Hors <le...@us.ibm.com>.
I introduced that in my changes to the DOM last week, it's now fixed. I
apology but none of the tests I had exhibited that bug. I now have one
that does.
--
Arnaud Le Hors - IBM, XML Standards Strategy Group / W3C AC Rep.
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
Re: Xerces-j regression: NullPointerException in
nextMatchingElementAfter
Posted by Arnaud Le Hors <le...@us.ibm.com>.
I introduced that in my changes to the DOM last week, it's now fixed. I
apology but none of the tests I had exhibited that bug. I now have one
that does.
--
Arnaud Le Hors - IBM, XML Standards Strategy Group / W3C AC Rep.