Ignore atime for directories

This commit is contained in:
hjp 2002-03-18 20:33:46 +00:00
parent 6f278ae0cb
commit a139e5334b
1 changed files with 7 additions and 4 deletions

View File

@ -1,6 +1,6 @@
#!@@@perl@@@ -w
#
# $Id: agestat.pl,v 1.4 2001-01-19 19:06:01 hjp Exp $
# $Id: agestat.pl,v 1.5 2002-03-18 20:33:46 hjp Exp $
#
use strict;
@ -33,7 +33,7 @@ sub wanted {
my $age = $now - (
$opts{atime} ? $st->atime :
$opts{mtime} ? $st->mtime :
($st->atime > $st->mtime ? $st->atime
(! -d && $st->atime > $st->mtime ? $st->atime
: $st->mtime ));
#print $File::Find::name, ": $age sec, ", $st->size, " bytes, ", $st->nlink, " links\n";
my $log2age = log($age >= 1 ? $age : 1) / $log_2;
@ -80,7 +80,10 @@ for (my $i = 0; $i <= $#hist; $i++) {
}
# $Log: agestat.pl,v $
# Revision 1.4 2001-01-19 19:06:01 hjp
# Revision 1.5 2002-03-18 20:33:46 hjp
# Ignore atime for directories
#
# Revision 1.4 2001/01/19 19:06:01 hjp
# Removed superfluous "total" line.
# Fixed usage message.
#