Skip Menu |

This queue is for tickets about the Socket-GetAddrInfo CPAN distribution.

Report information
The Basics
Id: 72341
Status: resolved
Priority: 0/
Queue: Socket-GetAddrInfo

People
Owner: Nobody in particular
Requestors: leonerd-cpan [...] leonerd.org.uk
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: 0.21
Fixed in:
  • 0.21_002
  • 0.22



Subject: Ability to getnameinfo on only host or service name
At the C level, one or other buffers to getnameinfo() can be NULL, so it doesn't look up the host or service name. The Perl API has no way to specify this so you can't, for example, avoid a DNS lookup. This should be added. Likely the simplest approach is to add a 3rd argument, taking two extra constants: my ( $err, $host, undef ) = getnameinfo $addr, $flags, NIx_NOSERVICE; my ( $err, undef, $service ) = getnameinfo $addr, $flags, NIx_NOHOST; -- Paul Evans
On Thu Nov 10 08:34:38 2011, PEVANS wrote: Show quoted text
> Likely the simplest approach is to add a 3rd argument, taking two extra > constants: > > my ( $err, $host, undef ) = getnameinfo $addr, $flags, NIx_NOSERVICE; > my ( $err, undef, $service ) = getnameinfo $addr, $flags, NIx_NOHOST;
Added in 0.21_002. -- Paul Evans
Released as 0.22 -- Paul Evans