mirror of
https://github.com/git/git.git
synced 2024-11-24 02:17:02 +08:00
commit: express tree entry constants in terms of the_hash_algo
Specify these constants in terms of the size of the hash algorithm currently in use. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
d9cd734990
commit
2770ccbdb2
4
commit.c
4
commit.c
@ -364,8 +364,8 @@ int parse_commit_buffer(struct commit *item, const void *buffer, unsigned long s
|
||||
struct object_id parent;
|
||||
struct commit_list **pptr;
|
||||
struct commit_graft *graft;
|
||||
const int tree_entry_len = GIT_SHA1_HEXSZ + 5;
|
||||
const int parent_entry_len = GIT_SHA1_HEXSZ + 7;
|
||||
const int tree_entry_len = the_hash_algo->hexsz + 5;
|
||||
const int parent_entry_len = the_hash_algo->hexsz + 7;
|
||||
|
||||
if (item->object.parsed)
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user