[openssl-commits] [openssl] master update
Matt Caswell
matt at openssl.org
Fri Aug 25 14:02:42 UTC 2017
The branch master has been updated
via bf208d9501b7b367da55236a418e6c3e09bf5877 (commit)
from ab78f89b2df6164826c1efb9aea4bf9edb269644 (commit)
- Log -----------------------------------------------------------------
commit bf208d9501b7b367da55236a418e6c3e09bf5877
Author: Matt Caswell <matt at openssl.org>
Date: Fri Aug 25 13:58:46 2017 +0100
Fix no-tls and no-tls1_2
Reviewed-by: Richard Levitte <levitte at openssl.org>
Reviewed-by: Rich Salz <rsalz at openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4257)
-----------------------------------------------------------------------
Summary of changes:
test/sslapitest.c | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/test/sslapitest.c b/test/sslapitest.c
index 4a9c075..70fbf80 100644
--- a/test/sslapitest.c
+++ b/test/sslapitest.c
@@ -757,6 +757,7 @@ static int test_tlsext_status_type(void)
}
#endif
+#if !defined(OPENSSL_NO_TLS1_3) || !defined(OPENSSL_NO_TLS1_2)
static int new_called, remove_called, get_called;
static int new_session_cb(SSL *ssl, SSL_SESSION *sess)
@@ -785,16 +786,15 @@ static SSL_SESSION *get_session_cb(SSL *ssl, const unsigned char *id, int len,
return get_sess_val;
}
-
static int execute_test_session(int maxprot, int use_int_cache,
int use_ext_cache)
{
SSL_CTX *sctx = NULL, *cctx = NULL;
SSL *serverssl1 = NULL, *clientssl1 = NULL;
SSL *serverssl2 = NULL, *clientssl2 = NULL;
-#ifndef OPENSSL_NO_TLS1_1
+# ifndef OPENSSL_NO_TLS1_1
SSL *serverssl3 = NULL, *clientssl3 = NULL;
-#endif
+# endif
SSL_SESSION *sess1 = NULL, *sess2 = NULL;
int testresult = 0;
@@ -918,7 +918,7 @@ static int execute_test_session(int maxprot, int use_int_cache,
&& (!TEST_int_eq(new_called, 0) || !TEST_int_eq(remove_called, 1)))
goto end;
-#if !defined(OPENSSL_NO_TLS1_1)
+# if !defined(OPENSSL_NO_TLS1_1)
new_called = remove_called = 0;
/* Force a connection failure */
SSL_CTX_set_max_proto_version(sctx, TLS1_1_VERSION);
@@ -938,7 +938,7 @@ static int execute_test_session(int maxprot, int use_int_cache,
/* Should succeed because it should not already be in the cache */
if (use_int_cache && !TEST_true(SSL_CTX_add_session(cctx, sess2)))
goto end;
-#endif
+# endif
/* Now do some tests for server side caching */
if (use_ext_cache) {
@@ -1035,10 +1035,10 @@ static int execute_test_session(int maxprot, int use_int_cache,
SSL_free(clientssl1);
SSL_free(serverssl2);
SSL_free(clientssl2);
-#ifndef OPENSSL_NO_TLS1_1
+# ifndef OPENSSL_NO_TLS1_1
SSL_free(serverssl3);
SSL_free(clientssl3);
-#endif
+# endif
SSL_SESSION_free(sess1);
SSL_SESSION_free(sess2);
SSL_CTX_free(sctx);
@@ -1046,6 +1046,7 @@ static int execute_test_session(int maxprot, int use_int_cache,
return testresult;
}
+#endif /* !defined(OPENSSL_NO_TLS1_3) || !defined(OPENSSL_NO_TLS1_2) */
static int test_session_with_only_int_cache(void)
{
More information about the openssl-commits
mailing list