diff options
author | Marcel Raad <raad@teamviewer.com> | 2017-04-08 13:40:41 +0200 |
---|---|---|
committer | Marcel Raad <raad@teamviewer.com> | 2017-04-08 13:40:41 +0200 |
commit | 45c78ad5b4883f0ce5978b36fb6a23fbd1f5e12b (patch) | |
tree | 14c0d0f85128512b78620fb7b8f3a4204d05be17 /lib/vtls/openssl.c | |
parent | e10db122a2ec085a4324f1addfa948838d5339fa (diff) | |
download | curl-45c78ad5b4883f0ce5978b36fb6a23fbd1f5e12b.tar.gz |
vtls: fix unreferenced variable warnings
... by moving the variables into the correct #ifdef block.
Diffstat (limited to 'lib/vtls/openssl.c')
-rw-r--r-- | lib/vtls/openssl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index f426f32ff..be264662a 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -1805,6 +1805,8 @@ static CURLcode ossl_connect_step1(struct connectdata *conn, int sockindex) long ctx_options = 0; #ifdef SSL_CTRL_SET_TLSEXT_HOSTNAME bool sni; + const char * const hostname = SSL_IS_PROXY() ? conn->http_proxy.host.name : + conn->host.name; #ifdef ENABLE_IPV6 struct in6_addr addr; #else @@ -1823,8 +1825,6 @@ static CURLcode ossl_connect_step1(struct connectdata *conn, int sockindex) const char * const ssl_capath = SSL_CONN_CONFIG(CApath); const bool verifypeer = SSL_CONN_CONFIG(verifypeer); const char * const ssl_crlfile = SSL_SET_OPTION(CRLfile); - const char * const hostname = SSL_IS_PROXY() ? conn->http_proxy.host.name : - conn->host.name; DEBUGASSERT(ssl_connect_1 == connssl->connecting_state); |