Fix error mapping when session is gracefully shutdown.
This commit is contained in:
parent
fa4b15aab8
commit
93bf0f4b8b
@ -194,9 +194,13 @@ const asio::error_code& engine::map_error_code(
|
||||
return ec;
|
||||
|
||||
// Otherwise, the peer should have negotiated a proper shutdown.
|
||||
ec = asio::error_code(
|
||||
ERR_PACK(ERR_LIB_SSL, 0, SSL_R_SHORT_READ),
|
||||
asio::error::get_ssl_category());
|
||||
if ((::SSL_get_shutdown(ssl_) & SSL_RECEIVED_SHUTDOWN) == 0)
|
||||
{
|
||||
ec = asio::error_code(
|
||||
ERR_PACK(ERR_LIB_SSL, 0, SSL_R_SHORT_READ),
|
||||
asio::error::get_ssl_category());
|
||||
}
|
||||
|
||||
return ec;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user