On 2025-02-17 at 01:24:14, Jared Van Bortel wrote: > Hi all, Hi, > I fat-fingered my enter key today and noticed this crash: > > $ git --version > git version 2.48.1 > $ mkdir foo && cd foo > $ git init > <snip> > $ git commit --allow-empty -m "foo" > [master (root-commit) ed4e080] foo > $ git log -S "" > BUG: diffcore-pickaxe.c:241: should have needle under -G or -S > [1] 65421 IOT instruction (core dumped) git log -S "" > $ git log -G "" > BUG: diffcore-pickaxe.c:241: should have needle under -G or -S > [1] 65457 IOT instruction (core dumped) git log -G "" > > > Well, it says BUG right there. It probably shouldn't crash. Relevant > backtrace for -S: Thanks for the report. I agree this is a bug and we shouldn't crash. I think the right thing to do here is reject empty arguments since those aren't actually very useful, so I'm in the process of writing a patch to do that now, which I'll send out either later this evening or tomorrow, depending on when CI finishes running. -- brian m. carlson (they/them or he/him) Toronto, Ontario, CA
Attachment:
signature.asc
Description: PGP signature