Return-Path: Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list commons-user@jakarta.apache.org Received: (qmail 10174 invoked from network); 18 Feb 2003 23:14:19 -0000 Received: from atlsmtp.jacada.com (12.166.230.15) by daedalus.apache.org with SMTP; 18 Feb 2003 23:14:19 -0000 Subject: Re: [JXPath] Infinite loop in iterator.hasNext() To: "Jakarta Commons Users List" X-Mailer: Lotus Notes Release 5.0.8 June 18, 2001 Message-ID: From: "Steve Pannier" Date: Tue, 18 Feb 2003 17:19:15 -0600 X-MIMETrack: Serialize by Router on Jacada_Atl_Smtp/CST(Release 5.0.8 |June 18, 2001) at 02/18/2003 06:05:54 PM MIME-Version: 1.0 Content-type: text/plain; charset=us-ascii X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Dmitri, One thing I forgot to ask in my last post: I have a Map (or a graph as you referred to it), and I want to verify that it contains no loops. Is there an easy way to do this? Any tool I can use? Or do I need to do this the old fashioned way? Thanks for your help. Steve Pannier Jacada, Inc. (763) 201-0002 Ext. 219 spannier@jacada.com http://www.jacada.com > I will wait for you test case before start seriously looking into this. > > Here's something that might help. If you have a graph with a loop (A points > to B and B points to A, directly or otherwise), and you launch a search like > this: "//foo", the whole thing has a good chance of falling into an infinite > loop, creating pointers of ever growing length. I have a plan to introduce > some automated detection of this situation, but at this point it will simply > lead to an OutOfMemoryError. Could this be it? > > - Dmitri > > ----- Original Message ----- > From: "Steve Pannier" > To: > Sent: Monday, February 17, 2003 2:58 PM > Subject: [JXPath] Infinite loop in iterator.hasNext() > > > > I've run into a problem with iterating through the result set after > > calling context.iterate(). As I'm iterating, the hasNext() method > > in my while loop conditional seems to get into an infinite loop. > > (I get several java.lang.OutOfMemoryError's - no stack trace > > available.) I did get a stack dump by sending the Unix QUIT > > signal to my running process, and the result of that is shown > > here: > >