From eda3c7d87b887c14843483978fb4ecd704ca45cc Mon Sep 17 00:00:00 2001 From: Sebastian Harl Date: Mon, 16 Feb 2015 09:04:18 +0100 Subject: [PATCH] ssl utils: During shutdown, destroy mutexes as the last step. Even ERR_free_strings() may call CRYPTO_lock. --- src/utils/ssl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/ssl.c b/src/utils/ssl.c index 0bd41a3..c6a3fcb 100644 --- a/src/utils/ssl.c +++ b/src/utils/ssl.c @@ -244,14 +244,14 @@ sdb_ssl_shutdown(void) { int i; + ERR_free_strings(); + for (i = 0; i < mutexes_num; ++i) pthread_mutex_destroy(&mutexes[i]); if (mutexes) free(mutexes); mutexes = NULL; mutexes_num = 0; - - ERR_free_strings(); } /* sdb_ssl_shutdown */ sdb_ssl_client_t * -- 2.30.2