diff -r 139808a46c7b -r cbff5ff61a0e exim-exigrey.pl --- a/exim-exigrey.pl Wed Jan 03 16:24:32 2007 +0000 +++ b/exim-exigrey.pl Wed Jan 03 16:58:30 2007 +0000 @@ -38,6 +38,7 @@ # # dbm file is relativ to $spool_directory/grey, EXCEPT its name # starts with "./" or "/". +# sub unseen($;$$) { my ($item, $delay, $db) = @_; $item .= "\0"; @@ -51,14 +52,15 @@ $db = connectDB(\%h, $db); if (not exists $h{$item}) { - $h{$item} = "$now $now\0"; + $h{$item} = "$now $now 0\0"; $rc = "yes"; } else { - my $created = (split " ", $h{$item})[0]; + my ($created, $used, $count) = split " ", $h{$item} if ($now - $created < $delay) { $rc = "yes" } else { $rc = "no"; - $h{$item} = "$created $now\0"; + ++$count; + $h{$item} = "$created $now $count\0"; } } untie %h;