summaryrefslogtreecommitdiff
path: root/fast-import.c
diff options
context:
space:
mode:
authorDerrick Stolee <dstolee@microsoft.com>2018-08-20 16:52:04 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-08-20 22:31:40 (GMT)
commit454ea2e4d7036862e8b2f69ef2dea640f8787510 (patch)
tree5c7d2c447869707b7519770b1a1b992555d63e14 /fast-import.c
parent0bff5269d3ed7124259bb3a5b33ddf2c4080b7e7 (diff)
downloadgit-454ea2e4d7036862e8b2f69ef2dea640f8787510.zip
git-454ea2e4d7036862e8b2f69ef2dea640f8787510.tar.gz
git-454ea2e4d7036862e8b2f69ef2dea640f8787510.tar.bz2
treewide: use get_all_packs
There are many places in the codebase that want to iterate over all packfiles known to Git. The purposes are wide-ranging, and those that can take advantage of the multi-pack-index already do. So, use get_all_packs() instead of get_packed_git() to be sure we are iterating over all packfiles. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'fast-import.c')
-rw-r--r--fast-import.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fast-import.c b/fast-import.c
index 89bb0c9..f8c3acd 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -1068,7 +1068,7 @@ static int store_object(
duplicate_count_by_type[type]++;
return 1;
} else if (find_sha1_pack(oid.hash,
- get_packed_git(the_repository))) {
+ get_all_packs(the_repository))) {
e->type = type;
e->pack_id = MAX_PACK_ID;
e->idx.offset = 1; /* just not zero! */
@@ -1266,7 +1266,7 @@ static void stream_blob(uintmax_t len, struct object_id *oidout, uintmax_t mark)
truncate_pack(&checkpoint);
} else if (find_sha1_pack(oid.hash,
- get_packed_git(the_repository))) {
+ get_all_packs(the_repository))) {
e->type = OBJ_BLOB;
e->pack_id = MAX_PACK_ID;
e->idx.offset = 1; /* just not zero! */