Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IO::Socket getsockopt on AIX [rt.cpan.org #91183] #17437

Open
toddr opened this issue Apr 19, 2018 · 0 comments
Open

IO::Socket getsockopt on AIX [rt.cpan.org #91183] #17437

toddr opened this issue Apr 19, 2018 · 0 comments
Labels
dist-IO issues in the dual-life blead-first IO distribution distro-aix

Comments

@toddr
Copy link
Member

toddr commented Apr 19, 2018

Migrated from rt.cpan.org#91183 (status was 'new')

Requestors:

From [email protected] on 2013-12-04 20:02:30:

Hi,

I've compiled Perl 5.18.1 which is bundled with IO::Socket 1.36 on AIX 7.1 
TL2 SP3.
The following configure command has been used to compile Perl: /usr/bin/sh 
./Configure -desr -Dprefix=/usr/local/perl-5.18.1 -Uman1direxp 
-Uman3direxp -Doptimize=-O2 -Duselongdoubles -Dusethreads

After that, I've tried to install a module named Mojolicious at version 
4.58 in which a test fail in t/mojo/daemon.t
The test is opening a socket without SO_REUSEPORT and validate with a 
getsockopt that it's not set.
It's expecting a false boolean but doesn't get one.
Our investigation brought us into IO/Socket.pm in subroutine getsockopt() 
on this condition:
    $r = unpack("i", $r)
        if(defined $r && length($r) == $intsize);
$r is defined andhas a length of 256
$intsize value is 4 so it's not unpacked and return something that is not 
a false boolean.
If I force unpack("i", $r), the value returned is 0 and the test pass.

Question: How can we explain that the length of $r is not $intsize? Would 
this require a change in IO::Socket Perl module or in my Perl compilation 
procedure or somewhere else?

In reference: 
https://groups.google.com/forum/#!topic/mojolicious/T34XZX72LaA


Best regards,

Yannick Bergeron
450 534-7711
[email protected]
Advisory IT Specialist
@toddr toddr transferred this issue from Dual-Life/IO Jan 20, 2020
@toddr toddr added Needs Triage dist-IO issues in the dual-life blead-first IO distribution labels Jan 20, 2020
@xenu xenu removed the Severity Low label Dec 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dist-IO issues in the dual-life blead-first IO distribution distro-aix
Projects
None yet
Development

No branches or pull requests

3 participants