Re: [PATCH] fmt-merge-msg: plug small leak of commit buffer

2015-04-20 Thread Junio C Hamano
Jeff King p...@peff.net writes: I note that record_person does not seem to care about the commit at all, so an alternative fix would be: diff --git a/builtin/fmt-merge-msg.c b/builtin/fmt-merge-msg.c index 1d962dc..9f0e608 100644 --- a/builtin/fmt-merge-msg.c +++ b/builtin/fmt-merge-msg.c

Re: [PATCH] fmt-merge-msg: plug small leak of commit buffer

2015-04-15 Thread Jeff King
On Wed, Apr 15, 2015 at 02:30:17PM -0700, Junio C Hamano wrote: I spoke too soon. There are two error-exit paths in this function. -- 8 -- A broken or badly formatted commit might not record author or committer lines or we may not find a valid name on them. The function record_person()

Re: [PATCH] fmt-merge-msg: plug small leak of commit buffer

2015-04-15 Thread Junio C Hamano
Junio C Hamano gits...@pobox.com writes: A broken or badly formatted commit might not record author or committer lines; the function record_person() returned after calling get_commit_buffer() without calling unuse_commit_buffer() on the memory, potentially leaking it. Signed-off-by: Junio C

[PATCH] fmt-merge-msg: plug small leak of commit buffer

2015-04-15 Thread Junio C Hamano
A broken or badly formatted commit might not record author or committer lines; the function record_person() returned after calling get_commit_buffer() without calling unuse_commit_buffer() on the memory, potentially leaking it. Signed-off-by: Junio C Hamano gits...@pobox.com --- * to be applied