my $pid = system_bg("cd /tmp ; sleep 50");
# do other stuff
while (still_alive($pid)) {
print STDERR "you are so lucky, your pid is still there\n";
}
print STDERR "ok, your pid has now finished\n";
preferably, this would work on most unix systems. I know that I can fork/exec, but this seems painful. has someone written such a module?
help appreciated.
sincerely,
/iaw
In reply to background system() and stillalive() sub by iaw4
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |