Hi All,
Has anyone ever ran a program in the background with a system call:
$status = system ( "run_program&" );
and then wanted to know when it finished? I have looked at articles on fork, wait, and waitpid, many of these appear to be the same obscure paragraph repeated over and over, apparently copied and pasted.
I would assume something like:
$process_id = system ( "run_program&" );
if ( ! $process_id )
{
print "You're finished!"
}
Any use of fork() gives me gobs of errors, resource ID in failed request, etc. There must be an easy way to do this..................................
Has anyone ever ran a program in the background with a system call:
$status = system ( "run_program&" );
and then wanted to know when it finished? I have looked at articles on fork, wait, and waitpid, many of these appear to be the same obscure paragraph repeated over and over, apparently copied and pasted.
I would assume something like:
$process_id = system ( "run_program&" );
if ( ! $process_id )
{
print "You're finished!"
}
Any use of fork() gives me gobs of errors, resource ID in failed request, etc. There must be an easy way to do this..................................