MCPcopy Create free account
hub / github.com/git/git / run_slot

Function run_slot

remote-curl.c:848–877  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

846}
847
848static int run_slot(struct active_request_slot *slot,
849 struct slot_results *results)
850{
851 int err;
852 struct slot_results results_buf;
853
854 if (!results)
855 results = &results_buf;
856
857 err = run_one_slot(slot, results);
858
859 if (err != HTTP_OK && err != HTTP_REAUTH) {
860 struct strbuf msg = STRBUF_INIT;
861 if (results->http_code && results->http_code != 200)
862 strbuf_addf(&msg, "HTTP %ld", results->http_code);
863 if (results->curl_result != CURLE_OK) {
864 if (msg.len)
865 strbuf_addch(&msg, ' ');
866 strbuf_addf(&msg, "curl %d", results->curl_result);
867 if (curl_errorstr[0]) {
868 strbuf_addch(&msg, ' ');
869 strbuf_addstr(&msg, curl_errorstr);
870 }
871 }
872 error(_("RPC failed; %s"), msg.buf);
873 strbuf_release(&msg);
874 }
875
876 return err;
877}
878
879static int probe_rpc(struct rpc_state *rpc, struct slot_results *results)
880{

Callers 2

probe_rpcFunction · 0.85
post_rpcFunction · 0.85

Calls 6

run_one_slotFunction · 0.85
strbuf_addfFunction · 0.85
strbuf_addchFunction · 0.85
strbuf_addstrFunction · 0.85
errorFunction · 0.85
strbuf_releaseFunction · 0.85

Tested by

no test coverage detected