mirror of
https://github.com/moparisthebest/curl
synced 2024-12-21 23:58:49 -05:00
connect/ntlm/http: Fixed compilation warnings when verbose strings disabled
warning C4189: 'data': local variable is initialized but not referenced
This commit is contained in:
parent
89f397d7eb
commit
9351383745
@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@ -859,8 +859,10 @@ CURLcode Curl_is_connected(struct connectdata *conn,
|
|||||||
|
|
||||||
void Curl_tcpnodelay(struct connectdata *conn, curl_socket_t sockfd)
|
void Curl_tcpnodelay(struct connectdata *conn, curl_socket_t sockfd)
|
||||||
{
|
{
|
||||||
#ifdef TCP_NODELAY
|
#if defined(TCP_NODELAY)
|
||||||
struct SessionHandle *data= conn->data;
|
#if !defined(CURL_DISABLE_VERBOSE_STRINGS)
|
||||||
|
struct SessionHandle *data = conn->data;
|
||||||
|
#endif
|
||||||
curl_socklen_t onoff = (curl_socklen_t) 1;
|
curl_socklen_t onoff = (curl_socklen_t) 1;
|
||||||
int level = IPPROTO_TCP;
|
int level = IPPROTO_TCP;
|
||||||
|
|
||||||
@ -877,6 +879,10 @@ void Curl_tcpnodelay(struct connectdata *conn, curl_socket_t sockfd)
|
|||||||
level = pe->p_proto;
|
level = pe->p_proto;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(CURL_DISABLE_VERBOSE_STRINGS)
|
||||||
|
(void) conn;
|
||||||
|
#endif
|
||||||
|
|
||||||
if(setsockopt(sockfd, level, TCP_NODELAY, (void *)&onoff,
|
if(setsockopt(sockfd, level, TCP_NODELAY, (void *)&onoff,
|
||||||
sizeof(onoff)) < 0)
|
sizeof(onoff)) < 0)
|
||||||
infof(data, "Could not set TCP_NODELAY: %s\n",
|
infof(data, "Could not set TCP_NODELAY: %s\n",
|
||||||
|
@ -170,6 +170,10 @@ static CURLcode ntlm_decode_type2_target(struct SessionHandle *data,
|
|||||||
unsigned short target_info_len = 0;
|
unsigned short target_info_len = 0;
|
||||||
unsigned int target_info_offset = 0;
|
unsigned int target_info_offset = 0;
|
||||||
|
|
||||||
|
#if defined(CURL_DISABLE_VERBOSE_STRINGS)
|
||||||
|
(void) data;
|
||||||
|
#endif
|
||||||
|
|
||||||
if(size >= 48) {
|
if(size >= 48) {
|
||||||
target_info_len = Curl_read16_le(&buffer[40]);
|
target_info_len = Curl_read16_le(&buffer[40]);
|
||||||
target_info_offset = Curl_read32_le(&buffer[44]);
|
target_info_offset = Curl_read32_le(&buffer[44]);
|
||||||
|
@ -567,10 +567,12 @@ output_auth_headers(struct connectdata *conn,
|
|||||||
{
|
{
|
||||||
const char *auth = NULL;
|
const char *auth = NULL;
|
||||||
CURLcode result = CURLE_OK;
|
CURLcode result = CURLE_OK;
|
||||||
|
#if !defined(CURL_DISABLE_VERBOSE_STRINGS) || defined(USE_SPNEGO)
|
||||||
struct SessionHandle *data = conn->data;
|
struct SessionHandle *data = conn->data;
|
||||||
|
#endif
|
||||||
#ifdef USE_SPNEGO
|
#ifdef USE_SPNEGO
|
||||||
struct negotiatedata *negdata = proxy?
|
struct negotiatedata *negdata = proxy ?
|
||||||
&data->state.proxyneg:&data->state.negotiate;
|
&data->state.proxyneg : &data->state.negotiate;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CURL_DISABLE_CRYPTO_AUTH
|
#ifdef CURL_DISABLE_CRYPTO_AUTH
|
||||||
|
Loading…
Reference in New Issue
Block a user