]> granicus.if.org Git - curl/commitdiff
schannel: fix unused variable warning
authorMarcel Raad <raad@teamviewer.com>
Thu, 30 Mar 2017 08:35:46 +0000 (10:35 +0200)
committerMarcel Raad <raad@teamviewer.com>
Thu, 30 Mar 2017 08:35:46 +0000 (10:35 +0200)
If CURL_DISABLE_VERBOSE_STRINGS is defined, hostname is not used in
schannel_connect_step3.

lib/vtls/schannel.c

index 0f59d9c4d4441d1ac71b8391bc934669f8dd28e8..6d83e9ed131d22472bbbfdd65c54e51f68b3bf4e 100644 (file)
@@ -690,8 +690,10 @@ schannel_connect_step3(struct connectdata *conn, int sockindex)
   struct ssl_connect_data *connssl = &conn->ssl[sockindex];
   SECURITY_STATUS sspi_status = SEC_E_OK;
   CERT_CONTEXT *ccert_context = NULL;
+#ifndef CURL_DISABLE_VERBOSE_STRINGS
   const char * const hostname = SSL_IS_PROXY() ? conn->http_proxy.host.name :
     conn->host.name;
+#endif
 #ifdef HAS_ALPN
   SecPkgContext_ApplicationProtocol alpn_result;
 #endif