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

Re: [PATCH] commit-graph: release strbufs after use

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 7, 2019, 19:25 UTC
Message-ID
<xmqqsgqchj73.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<a2f30b81-ba93-579c-98ec-07f5df1043d7@gmail.com>
Derrick Stolee <stolee@gmail.com> writes:
Show 8 quoted lines
> On 8/7/2019 7:15 AM, René Scharfe wrote:
>> Signed-off-by: René Scharfe <l.s.r@web.de>
>> ---
>> Patch generated with --function-context for easier review.  That makes
>> it look a lot bigger than it actually is, though.
>
> Thanks for the --function-context. It really does clarify what's going on,
> especially in the case with the "out:" label.
Yes in general, but it can cut both ways ;-)
Show 8 quoted lines
>> The plugged leaks were added after v2.22.0 (2019-06-07) by the following
>> commits:
>> 
>> 5c84b3396c 2019-06-18 commit-graph: load commit-graph chains
>> ef5b83f2cf 2019-06-12 commit-graph: extract fill_oids_from_packs()
>> 8d84097f96 2019-06-18 commit-graph: expire commit-graph files
>
> Your changes look good to me.
Thanks.
Show 10 quoted lines
>
>> -	strbuf_reset(&progress_title);
>> +	strbuf_release(&progress_title);
>
> This line confused me as I'm sure I adapted it from another place in code,
> and sure enough in the old code, progress_title was re-used between multiple
> stages. That's why it was a 'reset' when it should have been a 'release'.
>
> Thanks!
> -Stolee
Previous: Derrick Stolee
Message 3 of 3 in “commit-graph: release strbufs after use”
  1. commit-graph: release strbufs after useRené Scharfe, Aug 7, 2019
  2. Derrick StoleeAug 7, 2019
  3. Junio C HamanoAug 7, 2019

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.