Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Perl 5.8.3 and Solaris 8, use Socket problem?

by blue_cowdawg (Monsignor)
on Apr 25, 2004 at 18:19 UTC ( #347990=perlquestion: print w/replies, xml ) Need Help??

blue_cowdawg has asked for the wisdom of the Perl Monks concerning the following question:

Hi folks,

When I use Socket; in a script of mine that I recently wrote under Perl 5.8.3 under Solaris 8 I see the following spew:

Subroutine POSIX::WNOHANG redefined at /usr/local/software/perl-5.8.3/lib/5.8.3/sun4-solaris/POSIX.pm + line 48 (#1) (W redefine) You redefined a subroutine. To suppress this warning +, say { no warnings 'redefine'; eval "sub name { ... }"; }

Is anybody esle seeing this? Did I miss an FM to R?

Compilation was done with gcc

Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/ +specs gcc version 2.95.2 19991024 (release)
so the age of the compiler being the problem would not surprise me in the least.

Replies are listed 'Best First'.
Re: Perl 5.8.3 and Solaris 8, use Socket problem?
by bl0rf (Pilgrim) on Apr 25, 2004 at 19:41 UTC
    I would try something like:
    { no warnings; use POSIX; }
    Being a warning, I assume this doesn't interfere with the execution of your program, and you could safely ignore it. If you don't want users to see it, take out the use warnings or the -W switch from your script when you're done development.

      I'm going to try those ideas. I'm just wondering if there is something evil that building Perl on that machine did to Perl itself.

        gcc 2.95 might also be an issue. 3. is widely believed to solve some quirky anomalies.
Re: Perl 5.8.3 and Solaris 8, use Socket problem?
by dave_the_m (Monsignor) on Apr 26, 2004 at 12:46 UTC
    Do you have a small script that can reproduce this problem?

          Do you have a small script that can reproduce this problem?

      use Socket; : : : module stuff not shown for clarity my $name=gethostbyaddr(inet_aton($self->{ip}), AF_INET); # Lookup host +name
      There's the offending bits.

        Let me rephrase. Can you supply a *complete* script (preferably one that does not rely on non-core modules), and show the output of it failing? Ie there are many things that could trigger this problem, and I'd like to see as many of them as possible ruled out.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://347990]
Approved by ybiC
Front-paged by ysth
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (4)
As of 2022-06-29 13:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My most frequent journeys are powered by:









    Results (96 votes). Check out past polls.

    Notices?