Re: [PATCH v4 5/8] trailer: clarify failure modes in parse_trailer
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Oct 20, 2016, 22:45 UTC
- Message-ID
- <xmqqr37aej26.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <22e4b88b-5273-99c9-bcb3-0748c17a7229@google.com>
Jonathan Tan <jonathantanmy@google.com> writes:
Show 6 quoted lines
> If we do that, there is also the necessity of creating a string that > combines the separators and '=' (I guess '\n' is not necessary now, > since all the lines are null terminated). I'm OK either way. > > (We could cache that string, although I would think that if we did > that, we might as well write the loop manually, like in this patch.)
I wonder if there is a legit reason to look for '=' in the first place. "Signed-off-by= Jonathan Tan <jt@my.home>" does not look like a valid trailer line to me.
Isn't that a remnant of lazy coding in the original that tried to share a single parser for contents and command line options or something?