From: brian m. carlson Date: Sun, 18 Aug 2019 20:04:22 +0000 (+0000) Subject: packfile: replace sha1_to_hex X-Git-Tag: v2.24.0-rc0~40^2~5 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3a4d7aa5aeeeb6c0b3d92cbaee0d32c2c956c72b;p=git packfile: replace sha1_to_hex Replace a use of sha1_to_hex with hash_to_hex so that this code works with a hash algorithm other than SHA-1. Signed-off-by: brian m. carlson Signed-off-by: Junio C Hamano --- diff --git a/packfile.c b/packfile.c index fc43a6c52c..52dea88997 100644 --- a/packfile.c +++ b/packfile.c @@ -19,12 +19,12 @@ #include "commit-graph.h" char *odb_pack_name(struct strbuf *buf, - const unsigned char *sha1, + const unsigned char *hash, const char *ext) { strbuf_reset(buf); strbuf_addf(buf, "%s/pack/pack-%s.%s", get_object_directory(), - sha1_to_hex(sha1), ext); + hash_to_hex(hash), ext); return buf->buf; }