Skip to content

Commit aaa363e

Browse files
committed
fixup??? Always auto-gc after calling a fast-import transport
Needed by `rs/no-more-run-command-v`. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
1 parent 526b1f2 commit aaa363e

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

transport-helper.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -570,10 +570,11 @@ static int fetch_with_import(struct transport *transport,
570570
}
571571
strbuf_release(&buf);
572572
if (auto_gc) {
573-
const char *argv_gc_auto[] = {
574-
"gc", "--auto", "--quiet", NULL,
575-
};
576-
run_command_v_opt(argv_gc_auto, RUN_GIT_CMD);
573+
struct child_process cmd = CHILD_PROCESS_INIT;
574+
575+
cmd.git_cmd = 1;
576+
strvec_pushl(&cmd.args, "gc", "--auto", "--quiet", NULL);
577+
run_command(&cmd);
577578
}
578579
return 0;
579580
}

0 commit comments

Comments
 (0)