FS-5325 i'll put the nonblocking in but I still think this is a problem with openssl, a short read is not there every single time you connect, When the lib is in full blocking mode it should be handling the complicated actions internally. As complicated as socket programming is, async ssl is even worse because it requires you to do your own buffering and attemps to read may fail waiting for you to write or vice-versa which should have been handled for us in the lib. non-interruptable syscalls are getting pretty outdated and not enabling it is much less complex than making every socket app on earth be non-blocking
This commit is contained in:
parent
3847ae028a
commit
4f8faf9b78
|
@ -239,8 +239,8 @@ handshake (struct stream_data *data)
|
|||
if( SSL_set_fd(data->ssl, (int)(intptr_t)data->sock) != 1 ) return IKS_NOMEM;
|
||||
|
||||
/* Set both the read and write BIO's to non-blocking mode */
|
||||
//BIO_set_nbio(SSL_get_rbio(data->ssl), 1);
|
||||
//BIO_set_nbio(SSL_get_wbio(data->ssl), 1);
|
||||
BIO_set_nbio(SSL_get_rbio(data->ssl), 1);
|
||||
BIO_set_nbio(SSL_get_wbio(data->ssl), 1);
|
||||
|
||||
finished = 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue