mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 15:45:18 +00:00
tcptls: Avoiding ERR_remove_state in OpenSSL.
ERR_remove_state was deprecated with OpenSSL 1.0.0 and was replaced by
ERR_remove_thread_state. ERR_load_SSL_strings and ERR_load_BIO_strings were
called by SSL_load_error_strings already and got removed. These changes allow
OpenSSL forks like BoringSSL to be used with Asterisk.
ASTERISK-25043 #close
Reported by: Alexander Traud
patches:
asterisk_with_BoringSSL.patch uploaded by Alexander Traud (License 6520)
Change-Id: If1c0871ece21a7e0763fafbd2fa023ae49d4d629
(cherry picked from commit 247fef6653
)
This commit is contained in:
@@ -400,7 +400,11 @@ static int tcptls_stream_close(void *cookie)
|
||||
|
||||
if (!stream->ssl->server) {
|
||||
/* For client threads, ensure that the error stack is cleared */
|
||||
#if OPENSSL_VERSION_NUMBER >= 0x10000000L
|
||||
ERR_remove_thread_state(NULL);
|
||||
#else
|
||||
ERR_remove_state(0);
|
||||
#endif /* OPENSSL_VERSION_NUMBER >= 0x10000000L */
|
||||
}
|
||||
|
||||
SSL_free(stream->ssl);
|
||||
|
Reference in New Issue
Block a user