sslapitest: only compile test when it will be used
authorBenjamin Kaduk <bkaduk@akamai.com>
Wed, 1 Apr 2020 20:51:40 +0000 (13:51 -0700)
committerBenjamin Kaduk <kaduk@mit.edu>
Mon, 27 Apr 2020 23:22:48 +0000 (16:22 -0700)
The test_ccs_change_cipher() test routine is used only when TLS 1.2
is enabled; to fix the strict-warnings build we should not try to
compile it when TLS 1.2 is disabled, either.

Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/11458)

test/sslapitest.c

index f9349bc59b377a864a1394fede15793e815ff004..779176a0f11e4c78a6f3addd96782fa774ceca85 100644 (file)
@@ -659,7 +659,6 @@ end:
 
     return testresult;
 }
 
     return testresult;
 }
-#endif
 
 /*
  * Very focused test to exercise a single case in the server-side state
 
 /*
  * Very focused test to exercise a single case in the server-side state
@@ -771,6 +770,7 @@ end:
 
     return testresult;
 }
 
     return testresult;
 }
+#endif
 
 static int execute_test_large_message(const SSL_METHOD *smeth,
                                       const SSL_METHOD *cmeth,
 
 static int execute_test_large_message(const SSL_METHOD *smeth,
                                       const SSL_METHOD *cmeth,