From 21a5ea8088aaa3f12c8ec3a879b8e9218108adf7 Mon Sep 17 00:00:00 2001 From: Andreas Scherbaum Date: Mon, 27 Feb 2012 10:25:53 +0100 Subject: [PATCH] - fix bug in timeout handling --- docbot.pl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docbot.pl b/docbot.pl index eaa2b29..ec9d482 100755 --- a/docbot.pl +++ b/docbot.pl @@ -851,8 +851,10 @@ BEGIN { foreach my $session (keys(%main::sessions)) { if (defined(read_session_activity($session))) { - if (read_session_activity($session) < (time() - 180) and read_session_activity($session) < (time() - 240)) { - print_msg("Session $session timed out", INFO); + if (read_session_activity($session) < (time() - 180)) { + if (read_session_activity($session) > (time() - 240)) { + print_msg("Session $session timed out", INFO); + } # automatic reconnects should be done by a plugin } else { my $irc = $main::sessions{$session}{'session'}; -- 2.39.5