Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Sending multiple requests to a perl socket

by wjw (Curate)
on Sep 23, 2013 at 11:08 UTC ( #1055269=note: print w/replies, xml ) Need Help??


in reply to Sending multiple requests to a perl socket

my $sock = IO::Socket::INET->new( Proto=> "tcp", PeerAddr => "$IP", PeerPort => "$port") || die "Could not connect to host => $IP:$port \n"; print $sock $LOGINPDU."\n"; while($ans=<$sock>){ $ans1.=$ans; } $sock->flush(); if($ans1) { print $sock $transPDU."\n"; while($tns=<$sock>) { $tns.=$tns; } } $sock->close();
What problem are you seeing?
  • ...the majority is always wrong, and always the last to know about it...
  • The Spice must flow...
  • ..by my will, and by will alone.. I set my mind in motion

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1055269]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2016-12-05 06:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (72 votes). Check out past polls.