Re: [PATCH 0/6] revisions API: fix more memory leaks
- From
Jeff King <peff@peff.net>
- Date
- Jul 18, 2022, 15:14 UTC
- Message-ID
- <YtV40w0n9muPnM1O@coredump.intra.peff.net>
- In-Reply-To
- <cover-0.6-00000000000-20220713T130511Z-avarab@gmail.com>
On Wed, Jul 13, 2022 at 03:10:29PM +0200, Ævar Arnfjörð Bjarmason wrote:
Show 7 quoted lines
> Ævar Arnfjörð Bjarmason (6): > bisect.c: add missing "goto" for release_revisions() > test-fast-rebase helper: use release_revisions() (again) > log: make the intent of cmd_show()'s "rev.pending" juggling clearer > log: fix common "rev.pending" memory leak in "git show" > bisect.c: partially fix bisect_rev_setup() memory leak > revisions API: don't leak memory on argv elements that need free()-ing
This looks correct overall to me. I left a few comments:
- the readability tweaks in 3 and 4 I think are worth doing. If you
agree, I'd like to see that in a re-roll. - the bigger "rev_info owns its argv" option for patches 5 and 6 is a
good suggestion, I think, but maybe is a bigger change (though if
it's optional, it shouldn't need to affect any other callers). But
if it derails things, it may not be worth doing now. I can live
without it.-Peff