@@ -203,10 +203,8 @@ static void curl_setup_http(CURL *curl, const char *url,
203203 curl_easy_setopt (curl , CURLOPT_INFILE , buffer );
204204 curl_easy_setopt (curl , CURLOPT_INFILESIZE , buffer -> buf .len );
205205 curl_easy_setopt (curl , CURLOPT_READFUNCTION , fread_buffer );
206- #ifndef NO_CURL_IOCTL
207206 curl_easy_setopt (curl , CURLOPT_IOCTLFUNCTION , ioctl_buffer );
208207 curl_easy_setopt (curl , CURLOPT_IOCTLDATA , buffer );
209- #endif
210208 curl_easy_setopt (curl , CURLOPT_WRITEFUNCTION , write_fn );
211209 curl_easy_setopt (curl , CURLOPT_NOBODY , 0 );
212210 curl_easy_setopt (curl , CURLOPT_CUSTOMREQUEST , custom_req );
@@ -249,8 +247,6 @@ static void process_response(void *callback_data)
249247 finish_request (request );
250248}
251249
252- #ifdef USE_CURL_MULTI
253-
254250static void start_fetch_loose (struct transfer_request * request )
255251{
256252 struct active_request_slot * slot ;
@@ -299,7 +295,6 @@ static void start_mkcol(struct transfer_request *request)
299295 FREE_AND_NULL (request -> url );
300296 }
301297}
302- #endif
303298
304299static void start_fetch_packed (struct transfer_request * request )
305300{
@@ -605,7 +600,6 @@ static void finish_request(struct transfer_request *request)
605600 }
606601}
607602
608- #ifdef USE_CURL_MULTI
609603static int is_running_queue ;
610604static int fill_active_slot (void * unused )
611605{
@@ -629,7 +623,6 @@ static int fill_active_slot(void *unused)
629623 }
630624 return 0 ;
631625}
632- #endif
633626
634627static void get_remote_object_list (unsigned char parent );
635628
@@ -658,10 +651,8 @@ static void add_fetch_request(struct object *obj)
658651 request -> next = request_queue_head ;
659652 request_queue_head = request ;
660653
661- #ifdef USE_CURL_MULTI
662654 fill_active_slots ();
663655 step_active_slots ();
664- #endif
665656}
666657
667658static int add_send_request (struct object * obj , struct remote_lock * lock )
@@ -696,10 +687,8 @@ static int add_send_request(struct object *obj, struct remote_lock *lock)
696687 request -> next = request_queue_head ;
697688 request_queue_head = request ;
698689
699- #ifdef USE_CURL_MULTI
700690 fill_active_slots ();
701691 step_active_slots ();
702- #endif
703692
704693 return 1 ;
705694}
@@ -894,7 +883,7 @@ static struct remote_lock *lock_remote(const char *path, long timeout)
894883 slot -> results = & results ;
895884 curl_setup_http (slot -> curl , url , DAV_LOCK , & out_buffer , fwrite_buffer );
896885 curl_easy_setopt (slot -> curl , CURLOPT_HTTPHEADER , dav_headers );
897- curl_easy_setopt (slot -> curl , CURLOPT_FILE , & in_buffer );
886+ curl_easy_setopt (slot -> curl , CURLOPT_WRITEDATA , & in_buffer );
898887
899888 CALLOC_ARRAY (lock , 1 );
900889 lock -> timeout = -1 ;
@@ -1153,7 +1142,7 @@ static void remote_ls(const char *path, int flags,
11531142 curl_setup_http (slot -> curl , url , DAV_PROPFIND ,
11541143 & out_buffer , fwrite_buffer );
11551144 curl_easy_setopt (slot -> curl , CURLOPT_HTTPHEADER , dav_headers );
1156- curl_easy_setopt (slot -> curl , CURLOPT_FILE , & in_buffer );
1145+ curl_easy_setopt (slot -> curl , CURLOPT_WRITEDATA , & in_buffer );
11571146
11581147 if (start_active_slot (slot )) {
11591148 run_active_slot (slot );
@@ -1227,7 +1216,7 @@ static int locking_available(void)
12271216 curl_setup_http (slot -> curl , repo -> url , DAV_PROPFIND ,
12281217 & out_buffer , fwrite_buffer );
12291218 curl_easy_setopt (slot -> curl , CURLOPT_HTTPHEADER , dav_headers );
1230- curl_easy_setopt (slot -> curl , CURLOPT_FILE , & in_buffer );
1219+ curl_easy_setopt (slot -> curl , CURLOPT_WRITEDATA , & in_buffer );
12311220
12321221 if (start_active_slot (slot )) {
12331222 run_active_slot (slot );
@@ -1682,21 +1671,15 @@ static int delete_remote_branch(const char *pattern, int force)
16821671
16831672static void run_request_queue (void )
16841673{
1685- #ifdef USE_CURL_MULTI
16861674 is_running_queue = 1 ;
16871675 fill_active_slots ();
16881676 add_fill_function (NULL , fill_active_slot );
1689- #endif
16901677 do {
16911678 finish_all_active_slots ();
1692- #ifdef USE_CURL_MULTI
16931679 fill_active_slots ();
1694- #endif
16951680 } while (request_queue_head && !aborted );
16961681
1697- #ifdef USE_CURL_MULTI
16981682 is_running_queue = 0 ;
1699- #endif
17001683}
17011684
17021685int cmd_main (int argc , const char * * argv )
@@ -1770,10 +1753,6 @@ int cmd_main(int argc, const char **argv)
17701753 break ;
17711754 }
17721755
1773- #ifndef USE_CURL_MULTI
1774- die ("git-push is not available for http/https repository when not compiled with USE_CURL_MULTI" );
1775- #endif
1776-
17771756 if (!repo -> url )
17781757 usage (http_push_usage );
17791758
@@ -1786,9 +1765,7 @@ int cmd_main(int argc, const char **argv)
17861765
17871766 http_init (NULL , repo -> url , 1 );
17881767
1789- #ifdef USE_CURL_MULTI
17901768 is_running_queue = 0 ;
1791- #endif
17921769
17931770 /* Verify DAV compliance/lock support */
17941771 if (!locking_available ()) {
0 commit comments