Ensure all locks are properly cleaned up

Some locks were not being properly cleaned up during close down.

Reviewed-by: Richard Levitte <levitte@openssl.org>
This commit is contained in:
Matt Caswell
2016-03-11 21:53:18 +00:00
parent 085b386065
commit ff2344052b
9 changed files with 41 additions and 10 deletions

View File

@@ -467,10 +467,14 @@ void OPENSSL_cleanup(void)
"crypto_cleanup_all_ex_data_int()\n");
fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: "
"bio_sock_cleanup_int()\n");
fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: "
"bio_cleanup()\n");
fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: "
"evp_cleanup_int()\n");
fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: "
"obj_cleanup_int()\n");
fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: "
"err_cleanup()\n");
#endif
/*
* Note that cleanup order is important:
@@ -489,11 +493,11 @@ void OPENSSL_cleanup(void)
engine_cleanup_int();
#endif
crypto_cleanup_all_ex_data_int();
#ifndef OPENSSL_NO_SOCK
bio_sock_cleanup_int();
#endif
bio_cleanup();
evp_cleanup_int();
obj_cleanup_int();
err_cleanup();
base_inited = 0;
}