diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2012-05-24 20:55:44 +0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2012-05-24 10:37:48 -0700 |
commit | 4614043c8fd8972bcde4fbfce7a8d25dd6d206fd (patch) | |
tree | b259d95084bad3855fbe0e15fcc378fb9f33ec4a /t/t5300-pack-object.sh | |
parent | 8a2e163ccd03a12696cbf7518c0b742d313b6f02 (diff) | |
download | git-4614043c8fd8972bcde4fbfce7a8d25dd6d206fd.tar.gz |
index-pack: use streaming interface for collision test on large blobs
When putting whole objects in core is unavoidable, try match object
type and size first before actually inflating.
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5300-pack-object.sh')
-rwxr-xr-x | t/t5300-pack-object.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/t/t5300-pack-object.sh b/t/t5300-pack-object.sh index d9d856b87b..300ed910a5 100755 --- a/t/t5300-pack-object.sh +++ b/t/t5300-pack-object.sh @@ -418,4 +418,9 @@ test_expect_success \ 'test_must_fail git index-pack -o bad.idx test-3.pack 2>msg && grep "SHA1 COLLISION FOUND" msg' +test_expect_success \ + 'make sure index-pack detects the SHA1 collision (large blobs)' \ + 'test_must_fail git -c core.bigfilethreshold=1 index-pack -o bad.idx test-3.pack 2>msg && + grep "SHA1 COLLISION FOUND" msg' + test_done |