summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-05-19 23:54:59 (GMT)
committerJunio C Hamano <gitster@pobox.com>2021-05-19 23:54:59 (GMT)
commitbdff0419da0e81a6fb957d38fd6cff06e3ffb4e3 (patch)
treef48c24e26a24f32897d06db04d57e94c41fd5ada
parent33be431c0c7284c1adf0fe49f7838dbc8aee6ea9 (diff)
parent00bc8390d8cd764c52f0308b303a270e9bf57d84 (diff)
downloadgit-bdff0419da0e81a6fb957d38fd6cff06e3ffb4e3.zip
git-bdff0419da0e81a6fb957d38fd6cff06e3ffb4e3.tar.gz
git-bdff0419da0e81a6fb957d38fd6cff06e3ffb4e3.tar.bz2
Merge branch 'ew/sha256-clone-remote-curl-fix'
"git clone" from SHA256 repository by Git built with SHA-1 as the default hash algorithm over the dumb HTTP protocol did not correctly set up the resulting repository, which has been corrected. * ew/sha256-clone-remote-curl-fix: remote-curl: fix clone on sha256 repos
-rw-r--r--remote-curl.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/remote-curl.c b/remote-curl.c
index 0290b04..9d432c2 100644
--- a/remote-curl.c
+++ b/remote-curl.c
@@ -555,6 +555,8 @@ static void output_refs(struct ref *refs)
struct ref *posn;
if (options.object_format && options.hash_algo) {
printf(":object-format %s\n", options.hash_algo->name);
+ repo_set_hash_algo(the_repository,
+ hash_algo_by_ptr(options.hash_algo));
}
for (posn = refs; posn; posn = posn->next) {
if (posn->symref)