Re: [PATCH] commit: introduce set_merge_remote_desc()

2016-08-13 Thread Jeff King
On Sat, Aug 13, 2016 at 02:07:42PM +0200, René Scharfe wrote: > So let's turn this dish into a full menu: > > commit: use xstrdup() in get_merge_parent() > commit: factor out set_merge_remote_desc() > merge-recursive: fix verbose output for multiple base trees > commit: use FLEX_ARRAY in

Re: [PATCH] commit: introduce set_merge_remote_desc()

2016-08-13 Thread René Scharfe
Am 13.08.2016 um 11:23 schrieb Jeff King: On Sat, Aug 13, 2016 at 11:14:31AM +0200, René Scharfe wrote: Add a helper function for allocating, populating and attaching struct merge_remote_desc to a commit and use it consistently. It allocates the necessary memory in a single block.

Re: [PATCH] commit: introduce set_merge_remote_desc()

2016-08-13 Thread Jeff King
On Sat, Aug 13, 2016 at 11:14:31AM +0200, René Scharfe wrote: > Add a helper function for allocating, populating and attaching struct > merge_remote_desc to a commit and use it consistently. It allocates the > necessary memory in a single block. > > commit.c::get_merge_parent() forgot to check

[PATCH] commit: introduce set_merge_remote_desc()

2016-08-13 Thread René Scharfe
Add a helper function for allocating, populating and attaching struct merge_remote_desc to a commit and use it consistently. It allocates the necessary memory in a single block. commit.c::get_merge_parent() forgot to check for memory allocation failures of strdup(3).