From 5a5fd4335e46f3b8f77942efa985972ae6403500 Mon Sep 17 00:00:00 2001 From: unknown Date: Sun, 1 Mar 2015 06:19:38 +0400 Subject: modules/util.pl: diagnostics --- modules/util.pl | 3 +++ 1 file changed, 3 insertions(+) (limited to 'modules') diff --git a/modules/util.pl b/modules/util.pl index 375d2e5..dfb715b 100644 --- a/modules/util.pl +++ b/modules/util.pl @@ -6,6 +6,7 @@ use strict; use Term::ANSIColor qw (:constants); use Socket qw( inet_aton inet_ntoa ); use Data::Dumper; +use Carp qw(cluck); %::RISKS = ( @@ -112,6 +113,7 @@ sub speak #this item is a stub, dur sub hostip { + #cluck "Calling gethostbyname in hostip"; return gethostbyname($_[0]); } @@ -219,6 +221,7 @@ sub getHostIP my $host = join('.', unpack('C4', pack('N', (hex($splitip[6] . $splitip[7])^hex('ffffffff'))))); return dottedQuadToInt(undef, $host); } + #cluck "Calling gethostbyname in getHostIP"; my @resolve = gethostbyname($host); return unless @resolve; return dottedQuadToInt(undef, join('.', unpack('C4', $resolve[4]))); -- cgit v1.2.3