in reply to IO::Socket::SSL's select() ignores pending data
I recently played with non-blocking SSL stuff, and both timeout and select work fine for me that way.if ( $SSL_ERROR == SSL_WANT_READ) { select($rbits,undef,undef,...); sysread... } elsif ( $SSL_ERROR == SSL_WANT_WRITE) { select(undef,$wbits,undef,...); sysread... # YES, sysread! }
OTOH all that stuff is needed only for non-blocking code. If the only thing needed is timeout in blocking code, I'd just use alarm($timeout).
|
|---|