1
0
Fork 0
mirror of https://github.com/kakwa/uts-server synced 2025-07-04 20:47:09 +02:00

fix some memory leaks on openssl context cleanup

This commit is contained in:
kakwa 2016-09-05 20:24:47 +02:00
parent aa97d4699d
commit 236f0cf04c
5 changed files with 23 additions and 8 deletions

View file

@ -66,7 +66,7 @@ int add_oid_section(rfc3161_context *ct, CONF *conf) {
return 1;
}
void init_ssl(){
void init_ssl() {
SSL_load_error_strings();
ERR_load_BIO_strings();
SSL_library_init();
@ -74,6 +74,12 @@ void init_ssl(){
}
void free_ssl() {
CONF_modules_unload(1);
EVP_cleanup();
// ENGINE_cleanup();
ERR_remove_state(1);
CRYPTO_cleanup_all_ex_data();
EVP_cleanup();
ERR_free_strings();
}