sub isStale {
my ($file, $age) = @_;
+ &DEBUG("isStale: $file does not exist") unless ( -f $file);
return 1 unless ( -f $file);
- return 1 if (time() - (stat($file))[8] > $age*60*60*24);
- my $delta = time() - (stat($file))[8];
+ return 1 if (time() - (stat($file))[9] > $age*60*60*24);
+ my $delta = time() - (stat($file))[9];
my $hage = $age*60*60*24;
- &DEBUG("isStale: not stale! $delta < $hage ($age) ?");
+ &DEBUG("isStale: not stale! $delta < $hage");
return 0;
}
/\\\%/ and last;
/\\\_/ and last;
- # weird/special stuff. also old (stock) blootbot bugs.
+ # weird/special stuff. also old blootbot or stock infobot bugs.
$rhs =~ /( \Q$ident\E's|\Q$ident\E's )/i and last; # ownership.
# duplication.
}
}
-sub checkPing {
- &DEBUG("checkPing() called.");
- $conn->schedule(60, \&checkPing, "this is a test");
- $conn->sl("PING $server :".time());
-}
-
sub closePID {
return 1 unless (exists $file{PID});
return 1 unless ( -f $file{PID});