All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: git@vger.kernel.org
Cc: "Junio C Hamano" <gitster@pobox.com>,
	"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: [PATCH 00/11] built-ins: fix common memory leaks
Date: Thu, 30 Jun 2022 20:00:10 +0200	[thread overview]
Message-ID: <cover-00.11-00000000000-20220630T175714Z-avarab@gmail.com> (raw)

This is a series of trivial leak-fixes which allows us to mark a
significant number of new tests as entirely passing under
SANITIZE=leak.

Now that 2da81d1efb0 (Merge branch 'ab/plug-leak-in-revisions',
2022-06-07) has landed we're going to have more & more cases where
fixing just one leak will allow us to mark N tests as passing in their
entirety. This is the first stepping stone on the way to that end.

Ævar Arnfjörð Bjarmason (11):
  check-ref-format: fix trivial memory leak
  clone: fix memory leak in copy_ref() call
  submodule.c: free() memory from xgetcwd()
  revert: free "struct replay_opts" members
  cat-file: fix a memory leak in --batch-command mode
  merge-file: refactor for subsequent memory leak fix
  merge-file: fix memory leaks on error path
  checkout: add a missing clear_unpack_trees_porcelain()
  gc: fix a memory leak
  cat-file: fix a common "struct object_context" memory leak
  pull: fix a "struct oid_array" memory leak

 builtin/cat-file.c                   | 33 +++++++++++++++++++---------
 builtin/check-ref-format.c           | 11 +++++++---
 builtin/checkout.c                   |  1 +
 builtin/clone.c                      |  1 +
 builtin/gc.c                         |  8 ++++++-
 builtin/merge-file.c                 | 32 +++++++++++++++------------
 builtin/pull.c                       | 16 +++++++++-----
 builtin/revert.c                     |  3 +++
 submodule.c                          |  3 ++-
 t/t0028-working-tree-encoding.sh     |  1 +
 t/t1051-large-conversion.sh          |  2 ++
 t/t1402-check-ref-format.sh          |  1 +
 t/t3304-notes-mixed.sh               |  1 +
 t/t4044-diff-index-unique-abbrev.sh  |  2 ++
 t/t4140-apply-ita.sh                 |  1 +
 t/t5314-pack-cycle-detection.sh      |  4 ++--
 t/t5524-pull-msg.sh                  |  1 +
 t/t6403-merge-file.sh                |  2 ++
 t/t6417-merge-ours-theirs.sh         |  1 +
 t/t6422-merge-rename-corner-cases.sh |  1 +
 t/t8007-cat-file-textconv.sh         |  2 ++
 t/t8010-cat-file-filters.sh          |  2 ++
 t/t9101-git-svn-props.sh             |  1 -
 t/t9104-git-svn-follow-parent.sh     |  1 -
 t/t9132-git-svn-broken-symlink.sh    |  1 -
 t/t9301-fast-import-notes.sh         |  1 +
 26 files changed, 93 insertions(+), 40 deletions(-)

-- 
2.37.0.874.g7d3439f13c4


             reply	other threads:[~2022-06-30 18:00 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-30 18:00 Ævar Arnfjörð Bjarmason [this message]
2022-06-30 18:00 ` [PATCH 01/11] check-ref-format: fix trivial memory leak Ævar Arnfjörð Bjarmason
2022-06-30 21:55   ` Junio C Hamano
2022-06-30 18:00 ` [PATCH 02/11] clone: fix memory leak in copy_ref() call Ævar Arnfjörð Bjarmason
2022-06-30 22:03   ` Junio C Hamano
2022-06-30 18:00 ` [PATCH 03/11] submodule.c: free() memory from xgetcwd() Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 04/11] revert: free "struct replay_opts" members Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 05/11] cat-file: fix a memory leak in --batch-command mode Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 06/11] merge-file: refactor for subsequent memory leak fix Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 07/11] merge-file: fix memory leaks on error path Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 08/11] checkout: add a missing clear_unpack_trees_porcelain() Ævar Arnfjörð Bjarmason
2022-06-30 22:20   ` Junio C Hamano
2022-06-30 23:34     ` Ævar Arnfjörð Bjarmason
2022-06-30 23:45       ` Junio C Hamano
2022-06-30 18:00 ` [PATCH 09/11] gc: fix a memory leak Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 10/11] cat-file: fix a common "struct object_context" " Ævar Arnfjörð Bjarmason
2022-06-30 18:00 ` [PATCH 11/11] pull: fix a "struct oid_array" " Ævar Arnfjörð Bjarmason
2022-07-01 10:42 ` [PATCH v2 00/11] built-ins: fix common memory leaks Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 01/11] check-ref-format: fix trivial memory leak Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 02/11] clone: fix memory leak in wanted_peer_refs() Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 03/11] submodule.c: free() memory from xgetcwd() Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 04/11] revert: free "struct replay_opts" members Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 05/11] cat-file: fix a memory leak in --batch-command mode Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 06/11] merge-file: refactor for subsequent memory leak fix Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 07/11] merge-file: fix memory leaks on error path Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 08/11] checkout: avoid "struct unpack_trees_options" leak Ævar Arnfjörð Bjarmason
2022-07-01 20:25     ` Junio C Hamano
2022-07-01 10:42   ` [PATCH v2 09/11] gc: fix a memory leak Ævar Arnfjörð Bjarmason
2022-07-01 10:42   ` [PATCH v2 10/11] cat-file: fix a common "struct object_context" " Ævar Arnfjörð Bjarmason
2022-07-01 10:43   ` [PATCH v2 11/11] pull: fix a "struct oid_array" " Ævar Arnfjörð Bjarmason
2022-07-01 18:58   ` [PATCH v2 00/11] built-ins: fix common memory leaks Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cover-00.11-00000000000-20220630T175714Z-avarab@gmail.com \
    --to=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.