diff options
| author | Junio C Hamano <junkio@cox.net> | 2006-06-02 18:17:35 -0700 |
|---|---|---|
| committer | Junio C Hamano <junkio@cox.net> | 2006-06-02 18:17:35 -0700 |
| commit | 2f164c35fa8915ddd8e8a01809a9935ad900f13c (patch) | |
| tree | 4a8e5b79c63abd436aea600457775b5557937c25 /http.c | |
| parent | 20ff06805c66826404b154b9309a8581449af2b0 (diff) | |
| parent | 2052d146f60eaeeef50cb4d437e4a25051f8d8c3 (diff) | |
| download | git-2f164c35fa8915ddd8e8a01809a9935ad900f13c.tar.xz | |
Merge branch 'ds/doc' into jc/fmt-patch
* ds/doc:
Update documentation for git-format-patch
sha1_file: avoid re-preparing duplicate packs
handle concurrent pruning of packed objects
http: prevent segfault during curl handle reuse
Remove possible segfault in http-fetch.
gitk: show_error fix
[PATCH] gitk: start-up bugfix
[PATCH] gitk: Replace "git-" commands with "git "
[PATCH] gitk: Display commit messages with word wrap
gitk: Fix bug where page-up/down wouldn't always work properly
gitk: Fix display of "(...)" for parents/children we haven't drawn
send-email: only 'require' instead of 'use' Net::SMTP
Allow multiple -m options to git-commit.
Diffstat (limited to 'http.c')
| -rw-r--r-- | http.c | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -25,7 +25,6 @@ long curl_low_speed_limit = -1; long curl_low_speed_time = -1; struct curl_slist *pragma_header; -struct curl_slist *no_range_header; struct active_request_slot *active_queue_head = NULL; @@ -208,7 +207,6 @@ void http_init(void) curl_global_init(CURL_GLOBAL_ALL); pragma_header = curl_slist_append(pragma_header, "Pragma: no-cache"); - no_range_header = curl_slist_append(no_range_header, "Range:"); #ifdef USE_CURL_MULTI { @@ -344,9 +342,14 @@ struct active_request_slot *get_active_slot(void) slot->finished = NULL; slot->callback_data = NULL; slot->callback_func = NULL; + curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, NULL); curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, pragma_header); - curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, no_range_header); curl_easy_setopt(slot->curl, CURLOPT_ERRORBUFFER, curl_errorstr); + curl_easy_setopt(slot->curl, CURLOPT_CUSTOMREQUEST, NULL); + curl_easy_setopt(slot->curl, CURLOPT_READFUNCTION, NULL); + curl_easy_setopt(slot->curl, CURLOPT_WRITEFUNCTION, NULL); + curl_easy_setopt(slot->curl, CURLOPT_UPLOAD, 0); + curl_easy_setopt(slot->curl, CURLOPT_HTTPGET, 1); return slot; } |
