]> granicus.if.org Git - curl/commitdiff
ssl: fix compilation with OpenSSL 0.9.7
authorMichael Kaufmann <mail@michael-kaufmann.ch>
Tue, 13 Nov 2018 20:41:25 +0000 (21:41 +0100)
committerMichael Kaufmann <mail@michael-kaufmann.ch>
Wed, 21 Nov 2018 10:14:26 +0000 (11:14 +0100)
- ENGINE_cleanup() was used without including "openssl/engine.h"
- enable engine support for OpenSSL 0.9.7

Closes #3266

configure.ac
lib/vtls/openssl.c

index 68b464e66356698c218c4ca7c429f52ce5afe2fb..80f8ae1b9caf2d910a28ace097bd637606bb8027 100755 (executable)
@@ -1772,7 +1772,6 @@ if test -z "$ssl_backends" -o "x$OPT_SSL" != xno &&
     dnl as it's a macro that needs the header files be included)
 
     AC_CHECK_FUNCS( RAND_egd \
-                    ENGINE_cleanup \
                     SSL_get_shutdown \
                     SSLv2_client_method )
 
index f5c6fabb45082843f96130fdc191d0f81a5a6278..e6f9fba34fde9c59002de025eecb6eabe81fac0f 100644 (file)
@@ -69,7 +69,7 @@
 #include <openssl/ocsp.h>
 #endif
 
-#if (OPENSSL_VERSION_NUMBER >= 0x0090800fL) && /* 0.9.8 or later */     \
+#if (OPENSSL_VERSION_NUMBER >= 0x0090700fL) && /* 0.9.7 or later */     \
   !defined(OPENSSL_NO_ENGINE)
 #define USE_OPENSSL_ENGINE
 #include <openssl/engine.h>
@@ -1056,7 +1056,7 @@ static void Curl_ossl_cleanup(void)
   /* Free ciphers and digests lists */
   EVP_cleanup();
 
-#ifdef HAVE_ENGINE_CLEANUP
+#ifdef USE_OPENSSL_ENGINE
   /* Free engine list */
   ENGINE_cleanup();
 #endif