Skip Menu |
 

This queue is for tickets about the Socket CPAN distribution.

Report information
The Basics
Id: 96274
Status: resolved
Priority: 0/
Queue: Socket

People
Owner: Nobody in particular
Requestors: hsk [...] fli-leibniz.de
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 2.014
Fixed in: 2.015



Subject: remark on and issue with 2.014
Download (untitled) / with headers
text/plain 457b
a) third alternative in definition of REGEXP_IPv4_DECIMAL in Socket.pm is 1?[0-9]{1,2} -- shouldn't this be [01]?[0-9]{1,2} b) test "$err == 0 for 127.0.0.1/80/flags=AI_NUMERICHOST" (in getaddrinfo.t), new in 2.014, fails on my box, running "perl 5, version 18, subversion 1 (v5.18.1) built for mips3-n32": # Failed test '$err == 0 for 127.0.0.1/80/flags=AI_NUMERICHOST' # at t/getaddrinfo.t line 106. # $err is Servname not supported for ai_socktype
Download (untitled) / with headers
text/plain 895b
This is actually two issues ;) But I'll reply to them both On Fri Jun 06 04:29:54 2014, hsk@fli-leibniz.de wrote: Show quoted text
> a) third alternative in definition of REGEXP_IPv4_DECIMAL in Socket.pm > is 1?[0-9]{1,2} -- shouldn't this be [01]?[0-9]{1,2}
I'm not sure I can see why. Can you give an example of an address which would matter? Show quoted text
> b) test "$err == 0 for 127.0.0.1/80/flags=AI_NUMERICHOST" (in > getaddrinfo.t), new in 2.014, fails on my box, running "perl 5, > version 18, subversion 1 (v5.18.1) built for mips3-n32": > > # Failed test '$err == 0 for 127.0.0.1/80/flags=AI_NUMERICHOST' > # at t/getaddrinfo.t line 106. > # $err is Servname not supported for ai_socktype
Well,... boo. :( What OS is that? Maybe it needs the ai_socktype hint to be set to something, or else it won't reply. Can you try it out? Pass something like socktype => SOCK_STREAM in the hints. -- Paul Evans
From: hsk [...] fli-leibniz.de
Download (untitled) / with headers
text/plain 1.2k
Show quoted text
> > a) third alternative in definition of REGEXP_IPv4_DECIMAL in > > Socket.pm is 1?[0-9]{1,2} -- shouldn't this be [01]?[0-9]{1,2}
> > I'm not sure I can see why. Can you give an example of an address > which would matter?
007 :-) (well, the current RE allows 07, so it should allow 007 also - but maybe you're sure that no leading zeroes get tested and that's why i named it "remark" :-) Show quoted text
> > b) test "$err == 0 for 127.0.0.1/80/flags=AI_NUMERICHOST" (in > > getaddrinfo.t), new in 2.014, fails on my box, running "perl 5, > > version 18, subversion 1 (v5.18.1) built for mips3-n32": > > > > # Failed test '$err == 0 for 127.0.0.1/80/flags=AI_NUMERICHOST' > > # at t/getaddrinfo.t line 106. > > # $err is Servname not supported for ai_socktype
> > Well,... boo. :( What OS is that?
that's good ol' IRIX... Show quoted text
> Maybe it needs the ai_socktype hint > to be set to something, or else it won't reply. > > Can you try it out? Pass something like > socktype => SOCK_STREAM > in the hints.
this helps, thanks diff a/Socket-2.014/t/getaddrinfo.t b/Socket-2.014/t/getaddrinfo.t 105c105 < ( $err, @res ) = getaddrinfo( "127.0.0.1", 80, { flags => AI_NUMERICHOST } ); --- Show quoted text
> ( $err, @res ) = getaddrinfo( "127.0.0.1", 80, { flags => AI_NUMERICHOST, socktype => SOCK_STREAM } );
Download (untitled) / with headers
text/plain 944b
On Fri Jun 06 07:29:02 2014, hsk@fli-leibniz.de wrote: Show quoted text
> > > a) third alternative in definition of REGEXP_IPv4_DECIMAL in > > > Socket.pm is 1?[0-9]{1,2} -- shouldn't this be [01]?[0-9]{1,2}
> > > > I'm not sure I can see why. Can you give an example of an address > > which would matter?
> > 007 :-) > > (well, the current RE allows 07, so it should allow 007 also - but > maybe you're sure that no leading zeroes get tested and that's why i > named it "remark" :-)
Ahyes; curious. I thought I had copied it from Regexp::Common::net, though it appears slightly different. I'll adjust it to match. Show quoted text
> diff a/Socket-2.014/t/getaddrinfo.t b/Socket-2.014/t/getaddrinfo.t > 105c105 > < ( $err, @res ) = getaddrinfo( "127.0.0.1", 80, { flags => > AI_NUMERICHOST } ); > ---
> > ( $err, @res ) = getaddrinfo( "127.0.0.1", 80, { flags => > > AI_NUMERICHOST, socktype => SOCK_STREAM } );
Patch applied; will be in next release. -- Paul Evans
Released in 2.015 -- Paul Evans


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.