in reply to Re^3: Waiting for input, without sleep
in thread Waiting for input, without sleep
while($response = $sock->peek()) { if ($response ne '') { #verify the data print "Server Response: $response\n"; $response = (string2hex($response)); print "Server Response: $response\n"; last; } else { sleep 1; print "Waiting for a response!\n"; } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Waiting for input, without sleep
by jrsimmon (Hermit) on Jun 30, 2009 at 16:28 UTC | |
by Trihedralguy (Pilgrim) on Jun 30, 2009 at 16:36 UTC | |
by jrsimmon (Hermit) on Jun 30, 2009 at 16:45 UTC | |
by Trihedralguy (Pilgrim) on Jun 30, 2009 at 16:51 UTC |