in reply to How to see the processId of the process called by system command from perl
my $pid = fork; defined $pid or die "fork failed: $!"; if ($pid) { # in parent: waitpid $pid; # wait for the child, which's pid is in $pid } else { # in child: system ("R ..."); exit; }
|
|---|