summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: edb0e04)
raw | patch | inline | side by side (parent: edb0e04)
author | Brandon Casey <casey@nrlssc.navy.mil> | |
Thu, 11 Oct 2007 01:00:27 +0000 (20:00 -0500) | ||
committer | Shawn O. Pearce <spearce@spearce.org> | |
Tue, 16 Oct 2007 00:50:05 +0000 (20:50 -0400) |
Since "-a" is removed from the base repack command line,
we can simplify how we add additional options to this
command line when using --auto.
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
we can simplify how we add additional options to this
command line when using --auto.
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
builtin-gc.c | patch | blob | history |
diff --git a/builtin-gc.c b/builtin-gc.c
index 6323e0d9db9f2e0119bd52bdc45bb5d8434d355d..956c32d1af66444dae26a705159beba9adb7aba7 100644 (file)
--- a/builtin-gc.c
+++ b/builtin-gc.c
static int need_to_gc(void)
{
- int ac = 0;
-
/*
* Setting gc.auto and gc.autopacklimit to 0 or negative can
* disable the automatic gc.
* we run "repack -A -d -l". Otherwise we tell the caller
* there is no need.
*/
- argv_repack[ac++] = "repack";
if (too_many_packs())
- argv_repack[ac++] = "-A";
+ append_option(argv_repack, "-A", MAX_ADD);
else if (!too_many_loose_objects())
return 0;
- argv_repack[ac++] = "-d";
- argv_repack[ac++] = "-l";
- argv_repack[ac++] = NULL;
return 1;
}