fix
OBS-URL: https://build.opensuse.org/package/show/server:monitoring/monitoring-plugins-contentage?expand=0&rev=8
This commit is contained in:
parent
5ee9f53df3
commit
8676f76212
@ -116,7 +116,7 @@ sub check_dir($$$$){
|
||||
print "Working in $dir\n" if ($DEBUG);
|
||||
for my $file (readdir(DIR)) {
|
||||
# if ($recursive){
|
||||
# &check_dir("$dir/$file",$secwarn,$seccrit) if (-d "$dir/$_");
|
||||
# &check_dir("$dir/$file",$secwarn,$seccrit) if (-d "$dir/$file");
|
||||
# }
|
||||
$count++;
|
||||
next if (! -f "$dir/$file");
|
||||
@ -127,7 +127,7 @@ sub check_dir($$$$){
|
||||
my $mtime=stat("$dir/$file")->mtime;
|
||||
my $age = time() - $mtime;
|
||||
my $time=strftime("%a %b %e %H:%M:%S %Y",localtime($mtime));
|
||||
print "$_ : $mtime : $age sec\n" if ($DEBUG);
|
||||
print "$dir/$file : $mtime : $age sec\n" if ($DEBUG);
|
||||
if ( $age < 0 ){
|
||||
$res{'errorstr'}.="$dir/$file was modified in the future!\n";
|
||||
$res{'level'}=$ERRORS{'CRITICAL'};
|
||||
|
Loading…
Reference in New Issue
Block a user