Skip to content

Commit bdff041

Browse files
committed
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
2 parents 33be431 + 00bc839 commit bdff041

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

remote-curl.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -555,6 +555,8 @@ static void output_refs(struct ref *refs)
555555
struct ref *posn;
556556
if (options.object_format && options.hash_algo) {
557557
printf(":object-format %s\n", options.hash_algo->name);
558+
repo_set_hash_algo(the_repository,
559+
hash_algo_by_ptr(options.hash_algo));
558560
}
559561
for (posn = refs; posn; posn = posn->next) {
560562
if (posn->symref)

0 commit comments

Comments
 (0)