From ac56812a5a79b5187a89cb7dcd9078c11ffed54e Mon Sep 17 00:00:00 2001 From: icxcnika Date: Tue, 22 Apr 2014 23:46:10 +0400 Subject: added some things in gitignore, added connection tx/rx info to status reports, added exit, sync, and ping commands, bot says which channel a restricted person tries to use ops command on, blacklist system is more intelligent (reason, person adding, can be removed), added functionality for working with URLs, automatically retries to join channels that are throttled, make sure we send passwords to NickServ@services., fixed a scheduling loophole that was exploitable, greatly reduced startup warnings due to slow syncing --- modules/util.pl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'modules/util.pl') diff --git a/modules/util.pl b/modules/util.pl index 35a66ae..375d2e5 100644 --- a/modules/util.pl +++ b/modules/util.pl @@ -5,6 +5,7 @@ use warnings; use strict; use Term::ANSIColor qw (:constants); use Socket qw( inet_aton inet_ntoa ); +use Data::Dumper; %::RISKS = ( @@ -225,13 +226,13 @@ sub getHostIP sub getNickIP { - my ($module, $nick) = @_; + my ($module, $nick, $host) = @_; $nick = lc $nick; return unless defined($::sn{$nick}); if (defined($::sn{$nick}{ip})) { return $::sn{$nick}{ip}; } - my $host = $::sn{$nick}{host}; + $host = $::sn{$nick}{host} if (!defined($host)); my $ip = getHostIP(undef, $host); if (defined($ip)) { $::sn{$nick}{ip} = $ip; -- cgit v1.2.3