mirror of
https://github.com/git/git.git
synced 2026-01-09 17:46:37 +00:00
reftable/system: stop depending on "hash.h"
We include "hash.h" in "reftable/system.h" such that we can use hash format IDs as well as the raw size of SHA1 and SHA256. As we are in the process of converting the reftable library to become standalone we of course cannot rely on those constants anymore. Introduce a new `enum reftable_hash` to replace internal uses of the hash format IDs and new constants that replace internal uses of the hash size. Adapt the reftable backend to set up the correct hash function. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
88e297275b
commit
c2f08236ed
@@ -148,7 +148,7 @@ char *reftable_strdup(const char *str);
|
||||
/* Find the longest shared prefix size of `a` and `b` */
|
||||
int common_prefix_size(struct reftable_buf *a, struct reftable_buf *b);
|
||||
|
||||
int hash_size(uint32_t id);
|
||||
int hash_size(enum reftable_hash id);
|
||||
|
||||
/*
|
||||
* Format IDs that identify the hash function used by a reftable. Note that
|
||||
|
||||
Reference in New Issue
Block a user