TLS
- Corrected ::recv error handling.
This commit is contained in:
@@ -347,7 +347,13 @@ void TLSClient::recv (std::string& data)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Something happened.
|
// Something happened.
|
||||||
if (received < 0)
|
if (received < 0 && gnutls_error_is_fatal (received) == 0)
|
||||||
|
{
|
||||||
|
if (_debug)
|
||||||
|
std::cout << "c: WARNING " << gnutls_strerror (received) << "\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
else if (received < 0)
|
||||||
throw std::string (gnutls_strerror (received));
|
throw std::string (gnutls_strerror (received));
|
||||||
|
|
||||||
buffer [received] = '\0';
|
buffer [received] = '\0';
|
||||||
|
|||||||
Reference in New Issue
Block a user