summaryrefslogtreecommitdiff
path: root/builtin/gc.c
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/gc.c')
-rw-r--r--builtin/gc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin/gc.c b/builtin/gc.c
index cef38e5..3e67124 100644
--- a/builtin/gc.c
+++ b/builtin/gc.c
@@ -174,7 +174,6 @@ static int too_many_packs(void)
if (gc_auto_pack_limit <= 0)
return 0;
- prepare_packed_git();
for (cnt = 0, p = get_packed_git(the_repository); p; p = p->next) {
if (!p->pack_local)
continue;
@@ -481,7 +480,7 @@ int cmd_gc(int argc, const char **argv, const char *prefix)
return error(FAILED_RUN, rerere.argv[0]);
report_garbage = report_pack_garbage;
- reprepare_packed_git();
+ reprepare_packed_git(the_repository);
if (pack_garbage.nr > 0)
clean_pack_garbage();