changeset 21480:6660ab6ba3a3

lib-ssl-iostream: Call OBJ_cleanup() for all OpenSSL versions Just to reduce the #if checks that uglify the code.
author Timo Sirainen <timo.sirainen@dovecot.fi>
date Sun, 05 Feb 2017 21:31:08 +0200
parents 7bd5c8609f37
children 0f676a75b649
files src/lib-ssl-iostream/dovecot-openssl-common.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-ssl-iostream/dovecot-openssl-common.c	Sun Feb 05 21:10:04 2017 +0200
+++ b/src/lib-ssl-iostream/dovecot-openssl-common.c	Sun Feb 05 21:31:08 2017 +0200
@@ -86,9 +86,9 @@
 		ENGINE_finish(dovecot_openssl_engine);
 		dovecot_openssl_engine = NULL;
 	}
-#if OPENSSL_VERSION_NUMBER < 0x10001000L
+	/* OBJ_cleanup() is called automatically by EVP_cleanup() in
+	   newer versions. Doesn't hurt to call it anyway. */
 	OBJ_cleanup();
-#endif
 #ifdef HAVE_SSL_COMP_FREE_COMPRESSION_METHODS
 	SSL_COMP_free_compression_methods();
 #endif