[exim-cvs] OpenSSL: fix bulid on older library versions

Top Page
Delete this message
Reply to this message
Author: Exim Git Commits Mailing List
Date:  
To: exim-cvs
Subject: [exim-cvs] OpenSSL: fix bulid on older library versions
Gitweb: https://git.exim.org/exim.git/commitdiff/b008f54f89a3e1a0aae0c301122820b87a84d21a
Commit:     b008f54f89a3e1a0aae0c301122820b87a84d21a
Parent:     1f0be89381a057aaaaa4ecd4890d4597b7f6ce80
Author:     Jeremy Harris <jgh146exb@???>
AuthorDate: Mon Apr 20 11:30:28 2020 +0100
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Mon Apr 20 11:30:28 2020 +0100


    OpenSSL: fix bulid on older library versions


    Broken-by: a89b6bd32a
---
 src/src/tls-openssl.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)


diff --git a/src/src/tls-openssl.c b/src/src/tls-openssl.c
index 26cc986..f7ff459 100644
--- a/src/src/tls-openssl.c
+++ b/src/src/tls-openssl.c
@@ -2765,7 +2765,10 @@ if (rc <= 0)
       {
       uschar * s = US"SSL_accept";
       int r = ERR_GET_REASON(ERR_peek_error());
-      if (  r == SSL_R_WRONG_VERSION_NUMBER || r == SSL_R_VERSION_TOO_LOW
+      if (  r == SSL_R_WRONG_VERSION_NUMBER
+#ifdef SSL_R_VERSION_TOO_LOW
+         || r == SSL_R_VERSION_TOO_LOW
+#endif
          || r == SSL_R_UNKNOWN_PROTOCOL || r == SSL_R_UNSUPPORTED_PROTOCOL)
     s = string_sprintf("%s (%s)", s, SSL_get_version(server_ssl));
       (void) tls_error(s, NULL, sigalrm_seen ? US"timed out" : NULL, errstr);