diff options
author | Marcel Raad <raad@teamviewer.com> | 2017-03-29 13:16:25 +0200 |
---|---|---|
committer | Marcel Raad <raad@teamviewer.com> | 2017-03-29 20:16:09 +0200 |
commit | 9bc92eeb0e72454836fd83e3628d33ce63fabaf1 (patch) | |
tree | 6551d99a03fdd1c9fe634d64c95cbb7eb5cd34d4 /lib/curl_ntlm_core.c | |
parent | aced311d189a70c7d9b2d958739bcfc1231b3698 (diff) | |
download | curl-9bc92eeb0e72454836fd83e3628d33ce63fabaf1.tar.gz |
NTLM: check for features with #ifdef instead of #if
Feature defines are normally checked with #ifdef instead of #if in the rest of
the codebase. Additionally, some compilers warn when a macro is implicitly
evaluated to 0 because it is not defined, which was the case here.
Ref: https://github.com/curl/curl/pull/1362#discussion_r108605101
Closes https://github.com/curl/curl/pull/1367
Diffstat (limited to 'lib/curl_ntlm_core.c')
-rw-r--r-- | lib/curl_ntlm_core.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/curl_ntlm_core.c b/lib/curl_ntlm_core.c index e02983ce6..fb43dda19 100644 --- a/lib/curl_ntlm_core.c +++ b/lib/curl_ntlm_core.c @@ -501,7 +501,7 @@ CURLcode Curl_ntlm_core_mk_lm_hash(struct Curl_easy *data, return CURLE_OK; } -#if USE_NTRESPONSES +#ifdef USE_NTRESPONSES static void ascii_to_unicode_le(unsigned char *dest, const char *src, size_t srclen) { @@ -512,7 +512,7 @@ static void ascii_to_unicode_le(unsigned char *dest, const char *src, } } -#if USE_NTLM_V2 && !defined(USE_WINDOWS_SSPI) +#if defined(USE_NTLM_V2) && !defined(USE_WINDOWS_SSPI) static void ascii_uppercase_to_unicode_le(unsigned char *dest, const char *src, size_t srclen) @@ -597,7 +597,7 @@ CURLcode Curl_ntlm_core_mk_nt_hash(struct Curl_easy *data, return CURLE_OK; } -#if USE_NTLM_V2 && !defined(USE_WINDOWS_SSPI) +#if defined(USE_NTLM_V2) && !defined(USE_WINDOWS_SSPI) /* This returns the HMAC MD5 digest */ CURLcode Curl_hmac_md5(const unsigned char *key, unsigned int keylen, |