Commit e75daedf authored by Magnus Svensson's avatar Magnus Svensson

WL4189 Active state perl fixes

parent 87b91e54
......@@ -65,9 +65,11 @@ BEGIN {
#
use Memoize;
memoize('mixed_path');
memoize('native_path');
memoize('posix_path');
if (!IS_WIN32PERL){
memoize('mixed_path');
memoize('native_path');
memoize('posix_path');
}
sub mixed_path {
my ($path)= @_;
......
......@@ -212,6 +212,14 @@ sub timer {
};
$0= "safe_timer($duration)";
if (IS_WIN32PERL){
# Just a thread in same process
sleep($duration);
print STDERR "timer $$: expired after $duration seconds\n";
exit(0);
}
my $count_down= $duration;
while($count_down--){
......
......@@ -76,7 +76,7 @@ sub _kstat {
my ($self)= @_;
while (1){
my $instance_num= $self->{cpus} ? @{$self->{cpus}} : 0;
my $list= `kstat -p -m cpu_info -i $instance_num`;
my $list= `kstat -p -m cpu_info -i $instance_num 2> /dev/null`;
my @lines= split('\n', $list) or last; # Break loop
my $cpuinfo= {};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment