This is an automated email from the ASF dual-hosted git repository.
masaori pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new 58dc8b5 Fix directives for checking TS_USE_TLS_OCSP
58dc8b5 is described below
commit 58dc8b5cb7885a945eadb370e091f828bd199b56
Author: Masaori Koshiba <[email protected]>
AuthorDate: Wed Feb 27 08:51:57 2019 +0900
Fix directives for checking TS_USE_TLS_OCSP
---
iocore/net/OCSPStapling.cc | 2 +-
iocore/net/SSLNetProcessor.cc | 4 ++--
iocore/net/SSLUtils.cc | 4 ++--
src/traffic_server/InkAPI.cc | 2 +-
4 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/iocore/net/OCSPStapling.cc b/iocore/net/OCSPStapling.cc
index 26316ce..2ebae67 100644
--- a/iocore/net/OCSPStapling.cc
+++ b/iocore/net/OCSPStapling.cc
@@ -20,7 +20,7 @@
*/
#include "P_OCSPStapling.h"
-#ifdef TS_USE_TLS_OCSP
+#if TS_USE_TLS_OCSP
#include <openssl/ssl.h>
#include <openssl/ocsp.h>
diff --git a/iocore/net/SSLNetProcessor.cc b/iocore/net/SSLNetProcessor.cc
index 90c7a4e..bec9a3d 100644
--- a/iocore/net/SSLNetProcessor.cc
+++ b/iocore/net/SSLNetProcessor.cc
@@ -37,7 +37,7 @@ SSLNetProcessor ssl_NetProcessor;
NetProcessor &sslNetProcessor = ssl_NetProcessor;
SNIActionPerformer sni_action_performer;
-#ifdef TS_USE_TLS_OCSP
+#if TS_USE_TLS_OCSP
struct OCSPContinuation : public Continuation {
int
mainEvent(int /* event ATS_UNUSED */, Event * /* e ATS_UNUSED */)
@@ -76,7 +76,7 @@ SSLNetProcessor::start(int, size_t stacksize)
// Initialize SSL statistics. This depends on an initial set of certificates
being loaded above.
SSLInitializeStatistics();
-#ifdef TS_USE_TLS_OCSP
+#if TS_USE_TLS_OCSP
if (SSLConfigParams::ssl_ocsp_enabled) {
// Call the update initially to get things populated
ocsp_update();
diff --git a/iocore/net/SSLUtils.cc b/iocore/net/SSLUtils.cc
index 20bd0ea..145a6bb 100644
--- a/iocore/net/SSLUtils.cc
+++ b/iocore/net/SSLUtils.cc
@@ -980,7 +980,7 @@ SSLInitializeLibrary()
}
#endif
-#ifdef TS_USE_TLS_OCSP
+#if TS_USE_TLS_OCSP
ssl_stapling_ex_init();
#endif /* TS_USE_TLS_OCSP */
@@ -1447,7 +1447,7 @@
SSLMultiCertConfigLoader::init_server_ssl_ctx(std::vector<X509 *> &cert_list, co
SSL_CTX_set_alpn_select_cb(ctx, SSLNetVConnection::select_next_protocol,
nullptr);
#endif /* TS_USE_TLS_ALPN */
-#ifdef TS_USE_TLS_OCSP
+#if TS_USE_TLS_OCSP
if (SSLConfigParams::ssl_ocsp_enabled) {
Debug("ssl", "SSL OCSP Stapling is enabled");
SSL_CTX_set_tlsext_status_cb(ctx, ssl_callback_ocsp_stapling);
diff --git a/src/traffic_server/InkAPI.cc b/src/traffic_server/InkAPI.cc
index e7d1080..e214548 100644
--- a/src/traffic_server/InkAPI.cc
+++ b/src/traffic_server/InkAPI.cc
@@ -8984,7 +8984,7 @@ TSSslServerContextCreate(TSSslX509 cert, const char
*certname)
SSLConfigParams *config = SSLConfig::acquire();
if (config != nullptr) {
ret = reinterpret_cast<TSSslContext>(SSLCreateServerContext(config));
-#ifdef TS_USE_TLS_OCSP
+#if TS_USE_TLS_OCSP
if (ret && SSLConfigParams::ssl_ocsp_enabled && cert && certname) {
if (SSL_CTX_set_tlsext_status_cb(reinterpret_cast<SSL_CTX *>(ret),
ssl_callback_ocsp_stapling)) {
if (!ssl_stapling_init_cert(reinterpret_cast<SSL_CTX *>(ret),
reinterpret_cast<X509 *>(cert), certname)) {