summaryrefslogtreecommitdiff
path: root/http-push.c
diff options
context:
space:
mode:
authorNick Hengeveld <nickh@reactrix.com>2006-06-06 09:41:32 -0700
committerJunio C Hamano <junkio@cox.net>2006-06-06 14:18:00 -0700
commitb3ca4e4ebba6915ea534c4b82cfc5d6f10b4c283 (patch)
tree09e986524a45748ea0ef67b7188404d9f8bb11df /http-push.c
parentefd0201684c6e9bf663811dc849590b8fe27b8b2 (diff)
downloadgit-b3ca4e4ebba6915ea534c4b82cfc5d6f10b4c283.tar.gz
HTTP cleanup
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>
Diffstat (limited to 'http-push.c')
-rw-r--r--http-push.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/http-push.c b/http-push.c
index b1c018a089..40524a8593 100644
--- a/http-push.c
+++ b/http-push.c
@@ -788,6 +788,7 @@ static void finish_request(struct transfer_request *request)
}
}
+#ifdef USE_CURL_MULTI
void fill_active_slots(void)
{
struct transfer_request *request = request_queue_head;
@@ -821,6 +822,7 @@ void fill_active_slots(void)
slot = slot->next;
}
}
+#endif
static void get_remote_object_list(unsigned char parent);
@@ -851,8 +853,10 @@ static void add_fetch_request(struct object *obj)
request->next = request_queue_head;
request_queue_head = request;
+#ifdef USE_CURL_MULTI
fill_active_slots();
step_active_slots();
+#endif
}
static int add_send_request(struct object *obj, struct remote_lock *lock)
@@ -889,8 +893,10 @@ static int add_send_request(struct object *obj, struct remote_lock *lock)
request->next = request_queue_head;
request_queue_head = request;
+#ifdef USE_CURL_MULTI
fill_active_slots();
step_active_slots();
+#endif
return 1;
}
@@ -2523,7 +2529,9 @@ int main(int argc, char **argv)
if (objects_to_send)
fprintf(stderr, " sending %d objects\n",
objects_to_send);
+#ifdef USE_CURL_MULTI
fill_active_slots();
+#endif
finish_all_active_slots();
/* Update the remote branch if all went well */