in reply to IO::Select can_read/can_write timeout question

If you can both read and write from the socket, I wouldn't use can_read and can_write at all. I'd use IO::Select::select($sel, $sel, undef, $timeout); I'm assuming you close the connection or "ping" the other end on timeout. If not, you can simply use IO::Select::select($sel, $sel);