summaryrefslogtreecommitdiff
path: root/builtin/fsck.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 /builtin/fsck.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 'builtin/fsck.c')
-rw-r--r--builtin/fsck.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin/fsck.c b/builtin/fsck.c
index 250f5af..63c8578 100644
--- a/builtin/fsck.c
+++ b/builtin/fsck.c
@@ -740,7 +740,7 @@ int cmd_fsck(int argc, const char **argv, const char *prefix)
struct progress *progress = NULL;
if (show_progress) {
- for (p = get_packed_git(the_repository); p;
+ for (p = get_all_packs(the_repository); p;
p = p->next) {
if (open_pack_index(p))
continue;
@@ -749,7 +749,7 @@ int cmd_fsck(int argc, const char **argv, const char *prefix)
progress = start_progress(_("Checking objects"), total);
}
- for (p = get_packed_git(the_repository); p;
+ for (p = get_all_packs(the_repository); p;
p = p->next) {
/* verify gives error messages itself */
if (verify_pack(p, fsck_obj_buffer,