mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-04 12:20:42 +09:00
Fixed missing CRYPTO_cleanup_all_ex_data() in ssh_finalize
(cherry picked from commit 934252d6ca)
This commit is contained in:
committed by
Andreas Schneider
parent
e56aaf5f44
commit
a309c1b38e
@@ -71,17 +71,21 @@ int ssh_init(void) {
|
||||
@returns 0 otherwise
|
||||
*/
|
||||
int ssh_finalize(void) {
|
||||
ssh_threads_finalize();
|
||||
ssh_crypto_finalize();
|
||||
ssh_socket_cleanup();
|
||||
#ifdef HAVE_LIBGCRYPT
|
||||
gcry_control(GCRYCTL_TERM_SECMEM);
|
||||
#elif defined HAVE_LIBCRYPTO
|
||||
EVP_cleanup();
|
||||
CRYPTO_cleanup_all_ex_data();
|
||||
#endif
|
||||
#ifdef _WIN32
|
||||
WSACleanup();
|
||||
#endif
|
||||
/* It is important to finalize threading after CRYPTO because
|
||||
* it still depends on it */
|
||||
ssh_threads_finalize();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user