Perl-Sensitive Sunglasses | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Have you heard of the concept of simplifying to a small test case? Anyway that said AFAIKS the problem is that in your incredibly misnamed new_thread routine you are doing this:
So the child process is exiting but you are not decrementing the '$thread' count, at least in the code presented. Nor are you communicating its death to the parent. So the reason you are getting a no children error is simple -> *there are no children* because they have finished but the parent simply does not know it. At a glance I don't see how you think the IPC between parent and child is going to work, and given the length of your sample and what I find really inaccurate and annoying names (ie a forked kid is not a thread) a glance is all it is going to get. When you fork parent and child get copies of all data and handles. Independent* copies so if the kid does stuff to the data the parents data remains unchanged. * yes I understand COW. cheers tachyon In reply to Re: mixing multisockets and forks
by tachyon
|
|