This is a reroll of my attempt at freeing the memory allocated by `setup_unpack_trees_porcelain()`. The first two patches are identical to v2. The third patch no longer relies on rather intimate knowledge of which strings are on the heap and which pointers are duplicates. Instead, as suggested by Junio, I keep a separate string-list of strings to free. That should make things more future-proof. v2: https://public-inbox.org/git/cover.1526488122.git.martin.agren@xxxxxxxxx/ Martin Elijah Newren (1): merge-recursive: provide pair of `unpack_trees_{start,finish}()` Martin Ågren (2): merge: setup `opts` later in `checkout_fast_forward()` unpack_trees_options: free messages when done unpack-trees.h | 6 ++++++ builtin/checkout.c | 1 + merge-recursive.c | 30 ++++++++++++++++-------------- merge.c | 35 ++++++++++++++++++++--------------- unpack-trees.c | 23 +++++++++++++++++++---- 5 files changed, 62 insertions(+), 33 deletions(-) -- 2.17.0.840.g5d83f92caf