git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 0/2] Fix some old memory leaks in merge-ort and builtin/merge

From
Elijah Newren via GitGitGadget <gitgitgadget@gmail.com>
Date
Jan 20, 2022, 07:47 UTC
Message-ID
<pull.1200.git.git.1642664835.gitgitgadget@gmail.com>
This series fixes three memory leaks.

The first comes from a report at [1]. It's a leak in merge-ort that pre-dates the remerge-diff topic (technically traceable back 15.5 years ago across merge-recursive.c history) and is triggerable from a variety of testcases. I think I may have overlooked it previously just because there's other leaks in revision walking and this looks like one of those.

The next two leaks were ones in builtin/merge.c found while fixing the above leak; they are fixed together in the second patch.

[1] https://lore.kernel.org/git/220119.86pmonn2mb.gmgdl@evledraar.gmail.com/
Elijah Newren (2):
  merge-ort: fix memory leak in merge_ort_internal()
  merge: fix memory leaks in cmd_merge()
 builtin/merge.c |  6 +++++-
 merge-ort.c     | 10 +++++-----
 2 files changed, 10 insertions(+), 6 deletions(-)
base-commit: af4e5f569bc89f356eb34a9373d7f82aca6faa8a
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1200%2Fnewren%2Fmerge-leaks-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1200/newren/merge-leaks-v1
Pull-Request: https://github.com/git/git/pull/1200
-- 
gitgitgadget
Next: Elijah Newren via GitGitGadget
Message 1 of 4 in “Fix some old memory leaks in merge-ort and builtin/merge”
  1. 0/2 Fix some old memory leaks in merge-ort and builtin/mergeElijah Newren via GitGitGadget, Jan 20, 2022
  2. 1/2 merge-ort: fix memory leak in merge_ort_internal()Elijah Newren via GitGitGadget, Jan 20, 2022
  3. 2/2 merge: fix memory leaks in cmd_merge()Elijah Newren via GitGitGadget, Jan 20, 2022
  4. Junio C HamanoJan 22, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.