You can probably deduce where the uninitialized value lies by examining carefully the output of the printf(). I expect it's the gethostbyip($host) that's returning undef. In the getgostbyip sub you'll want to replace my $hostip = @_; with my $hostip = $_[0];. The way you've got it coded, $hostip will be set to the number of elements in @_ (which is "1" in this case.)
Cheers, Rob
Comment on Re: Getting "uninitialized value" that I can't figure out...