Commit b1ce9ad0 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

TLS fix

parent 2a2966aa
......@@ -645,8 +645,11 @@ sb_tls_bio_read( BIO *b, char *buf, int len )
ret = LBER_SBIOD_READ_NEXT( p->sbiod, buf, len );
BIO_clear_retry_flags( b );
if ( ret < 0 && errno == EWOULDBLOCK ) {
BIO_set_retry_read( b );
if ( ret < 0 ) {
int err = errno;
if ( err == EAGAIN || err == EWOULDBLOCK ) {
BIO_set_retry_read( b );
}
}
return ret;
......@@ -669,8 +672,11 @@ sb_tls_bio_write( BIO *b, const char *buf, int len )
ret = LBER_SBIOD_WRITE_NEXT( p->sbiod, (char *)buf, len );
BIO_clear_retry_flags( b );
if ( ret < 0 && errno == EWOULDBLOCK ) {
BIO_set_retry_write( b );
if ( ret < 0 ) {
int err = errno;
if ( err == EAGAIN || err == EWOULDBLOCK ) {
BIO_set_retry_write( b );
}
}
return ret;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment