t-rex has asked for the wisdom of the Perl Monks concerning the following question:
hello monks, i am trying something like
sub client_socket_create() { my $socket = new IO::Socket::INET ( PeerHost => 'ltsbml02.aus.stglabs.ibm.com', PeerPort => 7777, Proto => 'tcp', ); print "$socket \n"; return $socket; }
then my calling script calls client_main()passing this $socket but to my shock when i print this $socket in client_main() it gives me nothing a space just
sub client_main($) { my $socket = @_; print "$socket \n"; # some processing # }
what could i possibly doing wrong ?
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: socket programming error while using it in modular way
by hippo (Archbishop) on Jun 28, 2016 at 16:28 UTC | |
Re: socket programming error while using it in modular way
by Cow1337killr (Monk) on Jun 28, 2016 at 21:44 UTC |