Hi All,

I am new to DOM4J and I am getting the following exception in an existing system that 
I am supporting. We are using JDK 1.4.1.

NodeIterator nl = XPathAPI.selectNodeIterator( doc, xql );
while ( ( n = nl.nextNode () ) != null )
{
        //...some processing
}

the xql passed is "//docinfo" and when I serialised the document passed, I find that 
the node is present. Also this problem is occuring only for some xml files. Most of 
the files are getting through without any error. 

java.lang.NullPointerException
at org.apache.xml.dtm.ref.dom2dtm.DOM2DTM.nextNode(DOM2DTM.java:347)
at 
org.apache.xml.dtm.ref.DTMDefaultBaseTraversers$IndexedDTMAxisTraverser.getNextIndexed(DTMDefaultBaseTraversers.java:576)
at 
org.apache.xml.dtm.ref.DTMDefaultBaseTraversers$DescendantTraverser.next(DTMDefaultBaseTraversers.java:742)
at org.apache.xpath.axes.DescendantIterator.nextNode(DescendantIterator.java:274)
at org.apache.xpath.axes.LocPathIterator.runTo(LocPathIterator.java:802)
at org.apache.xml.dtm.ref.DTMNodeList.<init>(DTMNodeList.java:114)
at org.apache.xpath.objects.XNodeSet.nodelist(XNodeSet.java:384)
at org.apache.xpath.XPathAPI.selectNodeList(XPathAPI.java:205)
at org.apache.xpath.XPathAPI.selectNodeList(XPathAPI.java:182)
at 
com.lexisNexis.ftk.foundation.utils.FTKConfigAccessor.executeXpath(FTKConfigAccessor.java:1563)


regards,
Shekhar Srivastava,

N¬HS^µéX¬²š'²ŠÞu¼ˆÂâžìSºÚ+‰©l·ž.)îÆÛ¢¸š–šÞéíyÖò
©âzThm¸§°úÞ'^žÖt!¡ñž:(µç!ž‰h‚'¬-æëÞ+aŠx®‰ŸºwZ™éíj[-¢Ìµéšvh§ŠËkjØžm§ÿÚvÊ,vw(›ö‰ÝxïF¥–‡"w~·òŠ\–'$v‰¸Žë®f¢–)à–+-v‰¸Žë®X¬¶Ë(º·~Šàzw­†Ûi³ÿåŠËl²‹«qçè®§zßåŠËlþX¬¶)ß÷h›ˆî±ê

Reply via email to