From e706505921cb4b1de653c0314446eec294bcd51d Mon Sep 17 00:00:00 2001 From: Pragmatic Software Date: Wed, 9 Dec 2009 01:12:36 +0000 Subject: [PATCH] Corrected non-array-ref issue in check_message_history_timeout subroutine --- pbot2.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pbot2.pl b/pbot2.pl index 5e658926..b8cfa6b5 100755 --- a/pbot2.pl +++ b/pbot2.pl @@ -1666,7 +1666,7 @@ BEGIN { foreach my $channel (keys %{ $flood_watch{$nick} }) { plog "Checking [$nick][$channel]\n"; - my $length = $#{ $flood_watch{$nick}{$channel} } + 1; + my $length = $#{ $flood_watch{$nick}{$channel}{messages} } + 1; my %last = %{ @{ $flood_watch{$nick}{$channel}{messages} }[$length - 1] }; if($now - $last{timestamp} >= 60 * 60 * 24) {