aboutsummaryrefslogtreecommitdiff
path: root/http.c
Commit message (Collapse)AuthorAge
* Remove all void-pointer arithmetic.Florian Forster2006-06-20
| | | | | | | | ANSI C99 doesn't allow void-pointer arithmetic. This patch fixes this in various ways. Usually the strategy that required the least changes was used. Signed-off-by: Florian Forster <octo@verplant.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* HTTP cleanupNick Hengeveld2006-06-06
| | | | | | | | | | Fix broken build when USE_CURL_MULTI is not defined, as noted by Becky Bruce. During cleanup, free header slist that was created during init, as noted by Junio. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* http: prevent segfault during curl handle reuseNick Hengeveld2006-05-31
| | | | | | | | | | | | If a curl handle is configured with special options, they may reference information that is freed after the request is complete which can cause a segfault if the curl handle is reused for a different type of request. This patch resets these options to a safe state when a transfer slot is assigned to a new request. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Set HTTP user agent to git/GIT_VERSIONNick Hengeveld2006-04-04
| | | | | | | | Useful for diagnostics/troubleshooting to know which client versions are hitting your server. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* HTTP slot reuse fixesNick Hengeveld2006-03-10
| | | | | | | | Incorporate into http-push a fix related to accessing slot results after the slot was reused, and fix a case in run_active_slot where a finished slot wasn't detected if the slot was reused. Signed-off-by: Junio C Hamano <junkio@cox.net>
* http-fetch: Abort requests for objects which arrived in packsMark Wooding2006-02-07
| | | | | | | | | | In fetch_object, there's a call to release an object request if the object mysteriously arrived, say in a pack. Unfortunately, the fetch attempt for this object might already be in progress, and we'll leak the descriptor. Instead, try to tidy away the request. Signed-off-by: Mark Wooding <mdw@distorted.org.uk> Signed-off-by: Junio C Hamano <junkio@cox.net>
* http: Turn on verbose Curl messages if GIT_CURL_VERBOSE set in environmentMark Wooding2006-02-05
| | | | | Signed-off-by: Mark Wooding <mdw@distorted.org.uk> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Fix HTTP request result processing after slot reuseNick Hengeveld2006-01-31
| | | | | | | | Add a way to store the results of an HTTP request when a slot finishes so the results can be processed after the slot has been reused. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* http.c: reorder to avoid compilation failure.Junio C Hamano2005-11-19
| | | | | | | | Move the static function get_curl_handle() around to make sure its definition and declarations are seen by the compiler before its first use. Also remove an unused variable. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Isolate shared HTTP request functionalityNick Hengeveld2005-11-19
Move shared HTTP request functionality out of http-fetch and http-push, and replace the two fwrite_buffer/fwrite_buffer_dynamic functions with one fwrite_buffer function that does dynamic buffering. Use slot callbacks to process responses to fetch object transfer requests and push transfer requests, and put all of http-push into an #ifdef check for curl multi support. Signed-off-by: Nick Hengeveld <nickh@reactrix.com> Signed-off-by: Junio C Hamano <junkio@cox.net>