You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by am...@apache.org on 2014/09/25 05:24:55 UTC

git commit: Fix build error for SSL Cert Loader if no SNI.

Repository: trafficserver
Updated Branches:
  refs/heads/master 8566edca1 -> 0a9a63260


Fix build error for SSL Cert Loader if no SNI.


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/0a9a6326
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/0a9a6326
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/0a9a6326

Branch: refs/heads/master
Commit: 0a9a632608cdb0e6a10f009dd2d9a049b823aee5
Parents: 8566edc
Author: Alan M. Carroll <am...@apache.org>
Authored: Wed Sep 24 22:24:40 2014 -0500
Committer: Alan M. Carroll <am...@apache.org>
Committed: Wed Sep 24 22:24:40 2014 -0500

----------------------------------------------------------------------
 plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc | 12 ++++++++++++
 1 file changed, 12 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/0a9a6326/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc
----------------------------------------------------------------------
diff --git a/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc b/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc
index 61a3236..c6cb892 100644
--- a/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc
+++ b/plugins/experimental/ssl_cert_loader/ssl-cert-loader.cc
@@ -7,6 +7,7 @@
 # include <memory.h>
 # include <inttypes.h>
 # include <ts/ts.h>
+# include <ts/ink_config.h>
 # include <tsconfig/TsValue.h>
 # include <openssl/ssl.h>
 # include <openssl/x509.h>
@@ -21,6 +22,8 @@ using ts::config::Value;
 # define PN "ssl-cert-loader"
 # define PCP "[" PN " Plugin] "
 
+# if TS_USE_TLS_SNI
+
 namespace {
 
 class CertLookup {
@@ -537,3 +540,12 @@ TSPluginInit(int argc, const char *argv[]) {
   return;
 }
 
+# else // ! TS_USE_TLS_SNI
+
+void
+TSPluginInit(int, const char *[]) {
+    TSError(PCP "requires TLS SNI which is not available.");
+}
+
+# endif // TS_USE_TLS_SNI
+