зеркало из https://github.com/microsoft/git.git
builtin/pack-objects: make hash agnostic
Avoid hard-coding a hash size, instead preferring to use the_hash_algo. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Родитель
51ebf55b93
Коммит
207899137d
|
@ -879,7 +879,7 @@ static void write_reused_pack_one(size_t pos, struct hashfile *out,
|
|||
len = encode_in_pack_object_header(header, sizeof(header),
|
||||
OBJ_REF_DELTA, size);
|
||||
hashwrite(out, header, len);
|
||||
hashwrite(out, base_sha1, 20);
|
||||
hashwrite(out, base_sha1, the_hash_algo->rawsz);
|
||||
copy_pack_data(out, reuse_packfile, w_curs, cur, next - cur);
|
||||
return;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче