last-modified: remove double error message

When the user passes two revisions, they get the following output: $ git last-modified HEAD HEAD~ error: last-modified can only operate on one revision at a time error: unable to setup last-modified The error message about "unable to setup" is not very informative, remove it. Signed-off-by: Toon Claes <toon@iotcl.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Toon Claes committed Jan 30, 2026 at 15:26 UTC b768485c4b7ad0a80d0fd24ec941308b57ccb6ed
1 file changed +1 -1
builtin/last-modified.c
+1 -1
@@ -495,7 +495,7 @@ static int last_modified_init(struct last_modified *lm, struct repository *r,
495 lm->rev.bloom_filter_settings = get_bloom_filter_settings(lm->rev.repo);
496
497 if (populate_paths_from_revs(lm) < 0)
498 - return error(_("unable to setup last-modified"));
498 + return -1;
499
500 CALLOC_ARRAY(lm->all_paths, hashmap_get_size(&lm->paths));
501 lm->all_paths_nr = 0;