Bruno oliveira wrote:
> 
> Hi!

Hello,

> I want to start a program in perl but i need to keep
> the pid to be able to kill it in the future.
> 
> For exmple:
> 
> system("top &");
> 
> this would start "top", but then i wouldn't be able to
> identify the process in order to kill it. Is there a
> way to do this (other than using fork) ?

defined( my $pid = fork ) or die "Cannot fork: $!";
$pid and exec 'top' or die "Cannot exec 'top': $!";



John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to