MINOR: server: move the use_ssl field out of the ifdef USE_OPENSSL
Having it in the ifdef complicates certain operations which require
additional ifdefs just to access a member which could remain zero in
non-ssl cases. Let's move it out, it will not even increase the
struct size on 64-bit machines due to alignment.
diff --git a/src/server.c b/src/server.c
index 479631c..b58216e 100644
--- a/src/server.c
+++ b/src/server.c
@@ -1072,6 +1072,7 @@
goto out;
}
+ newsrv->use_ssl = curproxy->defsrv.use_ssl;
newsrv->check.use_ssl = curproxy->defsrv.check.use_ssl;
newsrv->check.port = curproxy->defsrv.check.port;
if (newsrv->check.port)
@@ -1096,9 +1097,6 @@
newsrv->onmarkedup = curproxy->defsrv.onmarkedup;
newsrv->consecutive_errors_limit
= curproxy->defsrv.consecutive_errors_limit;
-#ifdef OPENSSL
- newsrv->use_ssl = curproxy->defsrv.use_ssl;
-#endif
newsrv->uweight = newsrv->iweight
= curproxy->defsrv.iweight;