in reply to Re: chargen program is too slow / IO::Select socket handle outputting timing issue
in thread chargen program is too slow / IO::Select socket handle outputting timing issue
I'm not sure what you are trying to accomplish with this extra complexity. Just process the ready-to-read-from sockets first if there are any, then process the ready-to-write-to sockets if there are any.
Now I get an un-initialized error on this part in the actual gen_chars() sub : $sock_client_hash{$wrs->fileno}{bytes_recvd}++;
$wrs->send(chr($cc)) or close_socket($wrs); $cc++; $sock_client_hash{$wrs->fileno}{bytes_recvd}++;
If you close the socket, then fileno() will return undef. What did you expect?
- tye
|
|---|