summaryrefslogtreecommitdiff
path: root/builtin/commit-graph.c
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/commit-graph.c')
-rw-r--r--builtin/commit-graph.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/builtin/commit-graph.c b/builtin/commit-graph.c
index 4a70b33fb5..03a8331e2b 100644
--- a/builtin/commit-graph.c
+++ b/builtin/commit-graph.c
@@ -39,14 +39,17 @@ static struct object_directory *find_odb(struct repository *r,
{
struct object_directory *odb;
char *obj_dir_real = real_pathdup(obj_dir, 1);
+ struct strbuf odb_path_real = STRBUF_INIT;
prepare_alt_odb(r);
for (odb = r->objects->odb; odb; odb = odb->next) {
- if (!strcmp(obj_dir_real, real_path(odb->path)))
+ strbuf_realpath(&odb_path_real, odb->path, 1);
+ if (!strcmp(obj_dir_real, odb_path_real.buf))
break;
}
free(obj_dir_real);
+ strbuf_release(&odb_path_real);
if (!odb)
die(_("could not find object directory matching %s"), obj_dir);
@@ -140,7 +143,7 @@ static int graph_write(int argc, const char **argv)
OPT_INTEGER(0, "size-multiple", &split_opts.size_multiple,
N_("maximum ratio between two levels of a split commit-graph")),
OPT_EXPIRY_DATE(0, "expire-time", &split_opts.expire_time,
- N_("maximum number of commits in a non-base split commit-graph")),
+ N_("only expire files older than a given date-time")),
OPT_END(),
};