From 9ac827977b8f430906110ecd2030324248fff604 Mon Sep 17 00:00:00 2001 From: Runxi Yu Date: Sun, 16 Nov 2025 00:00:00 +0000 Subject: Support multiple hash sizes in one build --- pack_pack.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pack_pack.go') diff --git a/pack_pack.go b/pack_pack.go index eed3a4af..757c5c02 100644 --- a/pack_pack.go +++ b/pack_pack.go @@ -69,11 +69,11 @@ func (repo *Repository) packReadAt(loc packlocation, want Hash) (Object, error) return nil, err } data := body.Bytes() - if !verifyTypedObject(ty, data, want) { + if !verifyTypedObject(ty, data, want, repo.HashSize) { body.Release() return nil, ErrInvalidObject } - obj, err := parseObjectBody(ty, want, data) + obj, err := parseObjectBody(ty, want, data, repo.HashSize) body.Release() return obj, err } -- cgit v1.3.1-10-gc9f91