neilwatson has asked for the wisdom of the Perl Monks concerning the following question:
Greetings,
I have code.
#!/usr/bin/perl BEGIN { unshift @INC, "/home/neil/perl5/lib/perl5" } use strict; use warnings; use Socket qw( getaddrinfo getnameinfo );
I get this error.
"getaddrinfo" is not exported by the Socket module "getnameinfo" is not exported by the Socket module Can't continue after import errors at /home/neil/bin/ptr line 7. BEGIN failed--compilation aborted at /home/neil/bin/ptr line 7.
This is perl 5.10.1. The default installed Socket version is 1.82. I installed a later version of Socket (see BEGIN), v2.0006. Aren't these sub in Socket?
I'm not set on this path. My goal is to find a host name from an IP address that may be IPV4 or IPV6. I cannot know ahead of time which IP version might be presented.
Neil Watson
watson-wilson.ca
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: "getaddrinfo" is not exported by the Socket module
by toolic (Bishop) on Sep 29, 2012 at 17:54 UTC | |
|
Re: "getaddrinfo" is not exported by the Socket module
by syphilis (Archbishop) on Sep 30, 2012 at 05:13 UTC | |
by neilwatson (Priest) on Sep 30, 2012 at 16:17 UTC | |
|
Re: "getaddrinfo" is not exported by the Socket module
by neilwatson (Priest) on Sep 30, 2012 at 16:41 UTC | |
by toolic (Bishop) on Sep 30, 2012 at 17:05 UTC |