Fixup mtr_unique. Remove usage of ps and grep. Make it a module. Move _process_alive to Platform.pm. Rename opt_baseport to baseport, it's not an option

This commit is contained in:
Magnus Svensson 2008-08-10 19:46:43 +02:00
commit 182b14114a
5 changed files with 209 additions and 200 deletions

View file

@ -100,17 +100,6 @@ else
}
sub _process_alive {
my ($pid)= @_;
return kill(0, $pid) unless IS_WINDOWS;
my @list= split(/,/, `tasklist /FI "PID eq $pid" /NH /FO CSV`);
my $ret_pid= eval($list[1]);
return ($ret_pid == $pid);
}
sub new {
my $class= shift;