Subject: Re: [PATCH] last-modified: verify revision argument is a commit-ish

From: Junio C Hamano <[email-masked]>
Date: Mon, 12 Jan 2026 12:23:17 -0800

Toon Claes <[email-masked]> writes:

> Passing a tree OID to git-last-modified(1) would trigger BUG behavior.
>
>     git last-modified HEAD^{tree}
>     BUG: builtin/last-modified.c:456: paths remaining beyond boundary in last-modified

Of course, the starting point last-modified needs to be something
that will yield series of commits when given to get_revision() ;-)

> Fix this error by verifying the parsed revision is peels to a
> commit-ish.

OK.