Re: Perl Async .10

Re: Perl Async .10

am 04.10.2006 18:44:12 von xhoster

"Todd English" wrote:
> Thank you for the reply.
>
> > my hunch was that your problem occurred because you're deleting items
> > from the hash while iterating over it, but on second thought I'm not so
> > sure.
>
> I originally thought this as well, and had tried a couple of variants
> to the code I posted where I didn't mess with the proc hash until all
> procs had reported their return. But this didn't make any difference
> and upon further reflection I didn't think this was the case.

My original post on this topic apparently never showed up. The problem
seems to come from the "kill 9,..." in Async's sub DESTROY. An Async child
will inherit a copy of the objects to all of its older siblings from the
parent. When the child exits, it will kill all of it's older siblings.
Thus the program only works correctly if the children terminate in the same
order that they began, so that a younger child never has an extent older
sibling to kill out of order.

I have no idea why the kill is there, and getting rid of it makes the
problem go away.

Xho

--
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service $9.95/Month 30GB