Re: [PATCH] bisect--helper: avoid segfault with bad syntax in start --term-.+
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- May 20, 2020, 22:25 UTC
- Message-ID
- <CAPig+cT4kv1D6O5XnaihTODnoGtVeDdDmsPLX2g380r4+YK51w@mail.gmail.com>
- In-Reply-To
- <20200520195214.62655-1-carenas@gmail.com>
On Wed, May 20, 2020 at 3:52 PM Carlo Marcelo Arenas Belón <carenas@gmail.com> wrote:
Show 5 quoted lines
> 06f5608c14 (bisect--helper: `bisect_start` shell function partially in C, > 2019-01-02) adds a lax parser for `git bisect start` which could result > in a segfault under a bad syntax call. > > Detect if they are enough arguments left in the command line to use for
s/they/there/
> --term-{old,good,new,bad} and throw the same syntax error the old shell
> script will show if not.
>
> While at it, remove and unnecessary (and incomplete) check for unknowns/and/an/
> arguments. > > Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>