unless( fork )
{
exec "/some/cmd/here";
}
i believe your script hangs since your getppid never returns a 1. instead, it is returning the pid of the forked child's parent - in this case A.pl - which will not be process id 1. process id 1 is probably your box's /etc/init process if it's unix and not even there if on win32...
decnartne ~ entranced
In reply to Re: Proper Forking
by decnartne
in thread Proper Forking
by P0w3rK!d
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |