X-Git-Url: http://git.ipfire.org/?a=blobdiff_plain;f=config%2Fcfgroot%2Fgeneral-functions.pl;h=0577afe2809e62b3de113f96b3819ab04a43d917;hb=ca9c45b3f28aa497e4dec0e67cfc54cb69dc05a0;hp=f448c34befc7cf8af483f674f02665c0203d6a54;hpb=65ca3f05075a11e2bce7daef5980f9bb4715ae84;p=people%2Fpmueller%2Fipfire-2.x.git diff --git a/config/cfgroot/general-functions.pl b/config/cfgroot/general-functions.pl index f448c34bef..0577afe280 100644 --- a/config/cfgroot/general-functions.pl +++ b/config/cfgroot/general-functions.pl @@ -235,7 +235,13 @@ sub writehashpart sub age { my ($dev, $ino, $mode, $nlink, $uid, $gid, $rdev, $size, $atime, $mtime, $ctime, $blksize, $blocks) = stat $_[0]; - my $totalsecs = time() - $mtime; + my $t = time() - $mtime; + + return &format_time($t); +} + +sub format_time($) { + my $totalsecs = shift; my @s = (); my $secs = $totalsecs % 60;