diff options
-rw-r--r-- | src/mongo/util/net/ssl_manager_apple.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/mongo/util/net/ssl_manager_apple.cpp b/src/mongo/util/net/ssl_manager_apple.cpp index 6df69044dd8..71566aee663 100644 --- a/src/mongo/util/net/ssl_manager_apple.cpp +++ b/src/mongo/util/net/ssl_manager_apple.cpp @@ -1705,8 +1705,12 @@ Future<SSLPeerInfo> SSLManagerApple::parseAndValidatePeerCertificate( int SSLManagerApple::SSL_read(SSLConnectionInterface* conn, void* buf, int num) { auto ssl = checked_cast<SSLConnectionApple*>(conn)->get(); size_t read = 0; - uassertOSStatusOK(::SSLRead(ssl, static_cast<uint8_t*>(buf), num, &read), - SocketErrorKind::RECV_ERROR); + + const auto status = ::SSLRead(ssl, static_cast<uint8_t*>(buf), num, &read); + if (status != ::errSSLWouldBlock) { + uassertOSStatusOK(status, SocketErrorKind::RECV_ERROR); + } + return read; } |