Right - the child inherits the file descriptors of the parent, which is why you need to close them. So you can either close them before the fork, which will close them both for the parent and the child, or after the fork, which will close them for the child, but leave them open for the parent.
Perhaps I don't understand your question? Why wouldn't the child in this case continue running after the disconnect?
-- Dan
In reply to Re: Re: Re: Re: how to make a demon in perl?
by zigdon
in thread how to make a demon in perl?
by Sihal
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |