]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: ssl: guard SSL_CTX_set_msg_callback with SSL_CTRL_SET_MSG_CALLBACK macro
authorIlya Shipitsin <chipitsine@gmail.com>
Mon, 8 Feb 2021 11:55:06 +0000 (16:55 +0500)
committerWilliam Lallemand <wlallemand@haproxy.org>
Mon, 8 Feb 2021 12:49:41 +0000 (13:49 +0100)
both SSL_CTX_set_msg_callback and SSL_CTRL_SET_MSG_CALLBACK defined since
ea262260469e49149cb10b25a87dfd6ad3fbb4ba, we can safely switch to that guard
instead of OpenSSL version

src/ssl_sock.c

index 3105785032f553e3f7f41c9777f45c6d0e52610a..099e7f922721068eafb28b72152a18bfce1f57ae 100644 (file)
@@ -4411,7 +4411,7 @@ int ssl_sock_prepare_ctx(struct bind_conf *bind_conf, struct ssl_bind_conf *ssl_
 #endif /* OPENSSL_NO_DH */
 
        SSL_CTX_set_info_callback(ctx, ssl_sock_infocbk);
-#if HA_OPENSSL_VERSION_NUMBER >= 0x00907000L
+#ifdef SSL_CTRL_SET_MSG_CALLBACK
        SSL_CTX_set_msg_callback(ctx, ssl_sock_msgcbk);
 #endif
 #ifdef HAVE_OPENSSL_KEYLOG