in reply to Multiple forks get re-executed
If you comment the line beginning with my you have a normal sub (that should return undef btw). Don't make the die to exit, because there are Situations where it's needed.sub RUN { my$i;return$i||0if($i=fork)||!defined$i;die"\n"if"-".do #tasksub head { #your code here, you are forked already } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Multiple forks get re-executed
by chromatic (Archbishop) on Jul 10, 2001 at 02:25 UTC | |
by Anonymous Monk on Jul 10, 2001 at 13:11 UTC |