diff options
author | barkalow@iabervon.org <barkalow@iabervon.org> | 2005-07-31 15:59:20 -0400 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2005-07-31 16:28:56 -0700 |
commit | 9f6cf65e66c441d99f4838b6b74971d48c4efc72 (patch) | |
tree | a7e23a85bc1b47f7a2f95d3ab59b5556dbe2ae2a /http-pull.c | |
parent | a52b41b265969e51c8ddab1bc128928cd880bc3e (diff) | |
download | git-9f6cf65e66c441d99f4838b6b74971d48c4efc72.tar.gz git-9f6cf65e66c441d99f4838b6b74971d48c4efc72.tar.xz |
[PATCH] Fix support for old libcurl
Old libcurl has curl_easy_setopt(), and http-pull requires it; it just
doesn't have one of the options.
Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'http-pull.c')
-rw-r--r-- | http-pull.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/http-pull.c b/http-pull.c index da4d65ab9..38047e695 100644 --- a/http-pull.c +++ b/http-pull.c @@ -12,9 +12,6 @@ #if LIBCURL_VERSION_NUM < 0x070800 #define curl_global_init(a) do { /* nothing */ } while(0) #endif -#if LIBCURL_VERSION_NUM < 0x070907 -#define curl_easy_setopt(a, b, c) do { /* nothing */ } while(0) -#endif static CURL *curl; @@ -187,7 +184,9 @@ int main(int argc, char **argv) curl_ssl_verify = gitenv("GIT_SSL_NO_VERIFY") ? 0 : 1; curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, curl_ssl_verify); +#if LIBCURL_VERSION_NUM >= 0x070907 curl_easy_setopt(curl, CURLOPT_NETRC, CURL_NETRC_OPTIONAL); +#endif base = url; |