Skip to content

Commit

Permalink
configure: Detect SSL_COMP_free_compression_methods() by linking
Browse files Browse the repository at this point in the history
Fixes using libressl.
  • Loading branch information
sirainen committed Jun 28, 2016
1 parent 61d57ef commit f390486
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions m4/ssl.m4
Expand Up @@ -34,6 +34,9 @@ AC_DEFUN([DOVECOT_SSL], [
AC_CHECK_LIB(ssl, SSL_get_servername, [
AC_DEFINE(HAVE_SSL_GET_SERVERNAME,, [Build with TLS hostname support])
],, $SSL_LIBS)
AC_CHECK_LIB(ssl, SSL_COMP_free_compression_methods, [
AC_DEFINE(HAVE_SSL_COMP_FREE_COMPRESSION_METHODS,, [Build with SSL_COMP_free_compression_methods() support])
],, $SSL_LIBS)
fi
fi
AM_CONDITIONAL(BUILD_OPENSSL, test "$have_openssl" = "yes")
Expand Down
2 changes: 1 addition & 1 deletion src/lib-ssl-iostream/dovecot-openssl-common.c
Expand Up @@ -71,7 +71,7 @@ bool dovecot_openssl_common_global_unref(void)
#if OPENSSL_VERSION_NUMBER < 0x10001000L
OBJ_cleanup();
#endif
#if OPENSSL_VERSION_NUMBER >= 0x10002000L
#ifdef HAVE_SSL_COMP_FREE_COMPRESSION_METHODS
SSL_COMP_free_compression_methods();
#endif
ENGINE_cleanup();
Expand Down

0 comments on commit f390486

Please sign in to comment.