Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Infinite loop yet no loop

by gjb (Vicar)
on Mar 18, 2004 at 14:07 UTC ( [id://337769]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Infinite loop yet no loop

Are you sure the root of the tree is added? If not, and you don't handle this, nothing will ever be added.

Just my 2 cents, -gjb-

Replies are listed 'Best First'.
Re: Re: Infinite loop yet no loop
by ido50 (Scribe) on Mar 18, 2004 at 14:26 UTC
    Yes, the root is always created and is kind of a dummy entry.

    -------------------------
    Live fat, die young
Re: Re: Infinite loop yet no loop
by bart (Canon) on Mar 18, 2004 at 15:22 UTC
    Goog thinking.

    To the OP: keep track of whether anything changed in the loop, otherwise it's time to abort. For example keep track of the count of items in the buffer, and if it's the same before and after the iteration, nothing has changed, and it's useless to go on.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://337769]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.