aboutsummaryrefslogtreecommitdiffstats
path: root/remote-curl.c
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2024-12-17 07:43:56 +0100
committerJunio C Hamano <gitster@pobox.com>2024-12-18 10:44:31 -0800
commit6c27d22276b754e2214242de7a200b372aa611f6 (patch)
tree3313fc3031e4312498e596d96f55f90b2c650d1a /remote-curl.c
parentmailinfo: stop using `the_repository` (diff)
downloadgit-6c27d22276b754e2214242de7a200b372aa611f6.tar.gz
git-6c27d22276b754e2214242de7a200b372aa611f6.zip
credential: stop using `the_repository`
Stop using `the_repository` in the "credential" subsystem by passing in a repository when filling, approving or rejecting credentials. Adjust callers accordingly by using `the_repository`. While there may be some callers that have a repository available in their context, this trivial conversion allows for easier verification and bubbles up the use of `the_repository` by one level. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'remote-curl.c')
-rw-r--r--remote-curl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/remote-curl.c b/remote-curl.c
index a24e3a8b9a..1273507a96 100644
--- a/remote-curl.c
+++ b/remote-curl.c
@@ -942,7 +942,7 @@ static int post_rpc(struct rpc_state *rpc, int stateless_connect, int flush_rece
do {
err = probe_rpc(rpc, &results);
if (err == HTTP_REAUTH)
- credential_fill(&http_auth, 0);
+ credential_fill(the_repository, &http_auth, 0);
} while (err == HTTP_REAUTH);
if (err != HTTP_OK)
return -1;
@@ -1064,7 +1064,7 @@ retry:
rpc->any_written = 0;
err = run_slot(slot, NULL);
if (err == HTTP_REAUTH && !large_request) {
- credential_fill(&http_auth, 0);
+ credential_fill(the_repository, &http_auth, 0);
curl_slist_free_all(headers);
goto retry;
}