summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Holme <steve_holme@hotmail.com>2014-12-12 22:08:03 +0000
committerSteve Holme <steve_holme@hotmail.com>2014-12-12 22:34:18 +0000
commit24b30d259caf2317bc38873b2f6ee20dd9682cc7 (patch)
tree8e9147d3d06e461c4ccb96a051b179e500e0ecc6
parent82fdb87b275db7bbff512e04ed7cf199aa1da8d8 (diff)
downloadgnurl-24b30d259caf2317bc38873b2f6ee20dd9682cc7.tar.gz
gnurl-24b30d259caf2317bc38873b2f6ee20dd9682cc7.tar.bz2
gnurl-24b30d259caf2317bc38873b2f6ee20dd9682cc7.zip
smb: Disable SMB when 64-bit integers are not supported
This fixes compilation issues with compilers that don't support 64-bit integers through long long or __int64.
-rw-r--r--lib/smb.c5
-rw-r--r--lib/smb.h5
-rw-r--r--lib/url.c1
-rw-r--r--lib/version.c1
4 files changed, 8 insertions, 4 deletions
diff --git a/lib/smb.c b/lib/smb.c
index 4d556488e..5e329c154 100644
--- a/lib/smb.c
+++ b/lib/smb.c
@@ -22,7 +22,8 @@
#include "curl_setup.h"
-#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM)
+#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
+ (CURL_SIZEOF_CURL_OFF_T > 4)
#if !defined(USE_WINDOWS_SSPI) || defined(USE_WIN32_CRYPTO)
@@ -902,4 +903,4 @@ static CURLcode smb_parse_url_path(struct connectdata *conn)
#endif /* !USE_WINDOWS_SSPI || USE_WIN32_CRYPTO */
-#endif /* CURL_DISABLE_SMB && USE_NTLM */
+#endif /* CURL_DISABLE_SMB && USE_NTLM && CURL_SIZEOF_CURL_OFF_T > 4 */
diff --git a/lib/smb.h b/lib/smb.h
index 233f4abd6..4dd7c9a32 100644
--- a/lib/smb.h
+++ b/lib/smb.h
@@ -256,7 +256,8 @@ struct smb_tree_disconnect {
#endif /* BUILDING_CURL_SMB_C */
-#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM)
+#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
+ (CURL_SIZEOF_CURL_OFF_T > 4)
#if !defined(USE_WINDOWS_SSPI) || defined(USE_WIN32_CRYPTO)
@@ -265,6 +266,6 @@ extern const struct Curl_handler Curl_handler_smbs;
#endif /* !USE_WINDOWS_SSPI || USE_WIN32_CRYPTO */
-#endif /* CURL_DISABLE_SMB && USE_NTLM */
+#endif /* CURL_DISABLE_SMB && USE_NTLM && CURL_SIZEOF_CURL_OFF_T > 4 */
#endif /* HEADER_CURL_SMB_H */
diff --git a/lib/url.c b/lib/url.c
index d191678ca..5b7870f32 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -221,6 +221,7 @@ static const struct Curl_handler * const protocols[] = {
#endif
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
+ (CURL_SIZEOF_CURL_OFF_T > 4) && \
(!defined(USE_WINDOWS_SSPI) || defined(USE_WIN32_CRYPTO))
&Curl_handler_smb,
#ifdef USE_SSL
diff --git a/lib/version.c b/lib/version.c
index 83143f402..9ac922665 100644
--- a/lib/version.c
+++ b/lib/version.c
@@ -217,6 +217,7 @@ static const char * const protocols[] = {
"sftp",
#endif
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
+ (CURL_SIZEOF_CURL_OFF_T > 4) && \
(!defined(USE_WINDOWS_SSPI) || defined(USE_WIN32_CRYPTO))
"smb",
# ifdef USE_SSL