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::INET with non-blocking mode fails on Linux/SPARC #7259

Closed
p5pRT opened this issue Apr 22, 2004 · 9 comments
Closed

IO::Socket::INET with non-blocking mode fails on Linux/SPARC #7259

p5pRT opened this issue Apr 22, 2004 · 9 comments

Comments

@p5pRT
Copy link

p5pRT commented Apr 22, 2004

Migrated from rt.perl.org#29082 (status was 'abandoned')

Searchable as RT29082$

@p5pRT
Copy link
Author

p5pRT commented Apr 22, 2004

From baz@irc.msk.ru

Created by baz@irc.msk.ru

IO​::Socket​::INET fails on Linux/SPARC on receiving data when Timeout option is passed(non-blocking mode).

This is the test script​:

#!/usr/bin/perl -w

use IO​::Socket​::INET;

$sock = IO​::Socket​::INET->new(PeerAddr => 'www.ya.ru',
  PeerPort => '80', Proto => 'tcp', Timeout => 120) or return undef;
  #PeerPort => '80', Proto => 'tcp') or return undef;
$sock->write("GET / HTTP/1.0\r\n\r\n");
$sock->read($data,1024);
print "$data\n";
 
It doesn't work when Timeout option is passed.

Perl Info

Flags:
    category=library
    severity=high

Site configuration information for perl v5.8.2:

Configured by root at Tue Feb 10 16:24:19 MSK 2004.

Summary of my perl5 (revision 5.0 version 8 subversion 2) configuration:
  Platform:
    osname=linux, osvers=2.4.24-sparc, archname=sparc-linux
    uname='linux iron.desc.ru 2.4.24-sparc #2 smp þÔ× ñÎ× 8 00:00:12 msk 2004 sparc64 sun4u ti ultrasparc ii (blackbird) gnulinux '
    config_args='-des -Darchname=sparc-linux -Dcccdlflags=-fPIC -Dccdlflags=-rdynamic -Dcc=gcc -Dprefix=/usr -Dvendorprefix=/usr -Dsiteprefix=/usr -Dlocincpth=  -Doptimize=-mcpu=ultrasparc -O2 -pipe -Duselargefiles -Dd_dosuid -Dd_semctl_semun -Dscriptdir=/usr/bin -Dman3ext=3pm -Dcf_by=Gentoo -Ud_csh -Di_db -Di_ndbm -Ud_longdbl'
    hint=recommended, useposix=true, d_sigaction=define
    usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef
    useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=undef use64bitall=undef uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='gcc', ccflags ='-fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
    optimize='-mcpu=ultrasparc -O2 -pipe',
    cppflags='-DPERL5 -fno-strict-aliasing'
    ccversion='', gccversion='3.2.3 20030422 (Gentoo Linux 1.4 3.2.3-r2, propolice)', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
    d_longlong=define, longlongsize=8, d_longdbl=undef, longdblsize=
    ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='gcc', ldflags =' -L/usr/local/lib'
    libpth=/usr/local/lib /lib /usr/lib
    libs=-lpthread -lnsl -lndbm -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc
    perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc
    libc=/lib/libc-2.3.2.so, so=so, useshrplib=false, libperl=libperl.a
    gnulibc_version='2.3.2'
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic'
    cccdlflags='-fPIC', lddlflags='-shared -L/usr/local/lib'

Locally applied patches:
    


@INC for perl v5.8.2:
    /etc/perl
    /usr/lib/perl5/site_perl/5.8.2/sparc-linux
    /usr/lib/perl5/site_perl/5.8.2
    /usr/lib/perl5/site_perl/5.8.0/sparc-linux
    /usr/lib/perl5/site_perl/5.8.0
    /usr/lib/perl5/site_perl
    /usr/lib/perl5/vendor_perl/5.8.2/sparc-linux
    /usr/lib/perl5/vendor_perl/5.8.2
    /usr/lib/perl5/vendor_perl/5.8.0/sparc-linux
    /usr/lib/perl5/vendor_perl/5.8.0
    /usr/lib/perl5/vendor_perl
    /usr/lib/perl5/5.8.2/sparc-linux
    /usr/lib/perl5/5.8.2
    /usr/local/lib/site_perl
    /usr/lib/perl5/site_perl/5.8.0/sparc-linux
    /usr/lib/perl5/site_perl/5.8.0
    .


Environment for perl v5.8.2:
    HOME=/home/baz
    LANG=ru_RU.KOI8-R
    LANGUAGE (unset)
    LD_LIBRARY_PATH (unset)
    LOGDIR (unset)
    PATH=/bin:/usr/bin:/usr/local/bin:/opt/bin:/usr/sparc-unknown-linux-gnu/gcc-bin/3.2
    PERL_BADLANG (unset)
    SHELL=/bin/bash

@p5pRT
Copy link
Author

p5pRT commented Jul 4, 2004

From weeve@gentoo.org

This also happens in perl-5.8.4.

@p5pRT
Copy link
Author

p5pRT commented Jul 4, 2004

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Sep 15, 2004

From @iabyn

On Thu, Apr 22, 2004 at 04​:59​:52PM -0000, baz@​irc.msk.ru (via RT) wrote​:

IO​::Socket​::INET fails on Linux/SPARC on receiving data when Timeout option is passed(non-blocking mode).

This is the test script​:

#!/usr/bin/perl -w

use IO​::Socket​::INET;

$sock = IO​::Socket​::INET->new(PeerAddr => 'www.ya.ru',
PeerPort => '80', Proto => 'tcp', Timeout => 120) or return undef;
#PeerPort => '80', Proto => 'tcp') or return undef;
$sock->write("GET / HTTP/1.0\r\n\r\n");
$sock->read($data,1024);
print "$data\n";

It doesn't work when Timeout option is passed.

In what way exactly does it fail to work?

I can't get anything bad to happen on linux/x86 or solaris/sparc, and
I don't have access to a linux/sparc box.

Are there any other hardware/OS combinations which fail for you?

Dave.

--
Justice is when you get what you deserve.
Law is when you get what you pay for.

@p5pRT
Copy link
Author

p5pRT commented Sep 16, 2004

From guest@guest.guest.xxxxxxxx

[davem@​iabyn.com - Срд. Сен. 15 14​:37​:55 2004]​:

On Thu, Apr 22, 2004 at 04​:59​:52PM -0000, baz@​irc.msk.ru (via RT)
wrote​:

IO​::Socket​::INET fails on Linux/SPARC on receiving data when Timeout
option is passed(non-blocking mode).

This is the test script​:

#!/usr/bin/perl -w

use IO​::Socket​::INET;

$sock = IO​::Socket​::INET->new(PeerAddr => 'www.ya.ru',
PeerPort => '80', Proto => 'tcp', Timeout => 120) or return
undef;
#PeerPort => '80', Proto => 'tcp') or return undef;
$sock->write("GET / HTTP/1.0\r\n\r\n");
$sock->read($data,1024);
print "$data\n";

It doesn't work when Timeout option is passed.

In what way exactly does it fail to work?
it doesn't receive anything.

I can't get anything bad to happen on linux/x86 or solaris/sparc, and
I don't have access to a linux/sparc box.
this is linux/sparc only.
here is a fix http​://bugs.gentoo.org/show_bug.cgi?id=36478

@p5pRT
Copy link
Author

p5pRT commented Mar 24, 2012

From @jkeenan

On Thu Sep 16 00​:02​:04 2004, guest wrote​:

[davem@​iabyn.com - Срд. Сен. 15 14​:37​:55 2004]​:

On Thu, Apr 22, 2004 at 04​:59​:52PM -0000, baz@​irc.msk.ru (via RT)
wrote​:

IO​::Socket​::INET fails on Linux/SPARC on receiving data when Timeout
option is passed(non-blocking mode).

This is the test script​:

#!/usr/bin/perl -w

use IO​::Socket​::INET;

$sock = IO​::Socket​::INET->new(PeerAddr => 'www.ya.ru',
PeerPort => '80', Proto => 'tcp', Timeout => 120) or return
undef;
#PeerPort => '80', Proto => 'tcp') or return undef;
$sock->write("GET / HTTP/1.0\r\n\r\n");
$sock->read($data,1024);
print "$data\n";

It doesn't work when Timeout option is passed.

In what way exactly does it fail to work?
it doesn't receive anything.

I can't get anything bad to happen on linux/x86 or solaris/sparc, and
I don't have access to a linux/sparc box.
this is linux/sparc only.
here is a fix http​://bugs.gentoo.org/show_bug.cgi?id=36478

Is there anyone with access to Linux/sparc who could evaluate whether
the problem reported persists with supported versions of Perl 5 and
IO​::Socket​::INET?

Thank you very much.
Jim Keenan

@p5pRT
Copy link
Author

p5pRT commented Jul 6, 2016

From @dcollinsn

No response to a question four years ago of whether this is still a problem.

@p5pRT
Copy link
Author

p5pRT commented Jul 6, 2016

From [Unknown Contact. See original ticket]

No response to a question four years ago of whether this is still a problem.

@p5pRT
Copy link
Author

p5pRT commented Jul 6, 2016

@dcollinsn - Status changed from 'open' to 'abandoned'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants