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

Re: [PATCH] 2.36 fast-export regression fix

From
Junio C Hamano <gitster@pobox.com>
Date
Apr 30, 2022, 20:50 UTC
Message-ID
<xmqq35hu8feo.fsf@gitster.g>
In-Reply-To
<2c988c7b-0efe-4222-4a43-8124fe1a9da6@web.de>
René Scharfe <l.s.r@web.de> writes:
Show 11 quoted lines
> e900d494dc (diff: add an API for deferred freeing, 2021-02-11) added a
> way to allow reusing diffopts: the no_free bit.  244c27242f (diff.[ch]:
> have diff_free() call clear_pathspec(opts.pathspec), 2022-02-16) made
> that mechanism mandatory.
>
> git fast-export doesn't set no_free, so path limiting stopped working
> after the first commit.  Set the flag and add a basic test to make sure
> only changes to the specified files are exported.
>
> Signed-off-by: René Scharfe <l.s.r@web.de>
> ---
Both format-patch fix and this one look good to me.

We have UNLEAK() in format-patch so that the fix will not result in additional false positives from the leak checker. But this one, we didn't have UNLEAK() so this may start tickling the leak checker again. We may need to add UNLEAK() at some point.

Stopping a leak checker from complaining about a known singleton leak that is at the top-level (i.e. does not become bigger with the data) by spending extra cycles is pointless, compared to using UNLEAK() to do the same, and it is doubly misguided if it breaks the behaviour X-<.

Will queue both, thanks.
Previous: René Scharfe
Message 10 of 10 in “Bug: `git show` honors path filters only for the first commit”
  1. Daniel LiApr 30, 2022
  2. Junio C HamanoApr 30, 2022
  3. 2.36 show regression fixJunio C Hamano, Apr 30, 2022
  4. 2.36 format-patch regression fixRené Scharfe, Apr 30, 2022
  5. Carlo Marcelo Arenas BelónApr 30, 2022
  6. René ScharfeMay 1, 2022
  7. the state of diff_free() and release_revisions() (was: [PATCH] 2.36 format-patch regression fix)Ævar Arnfjörð Bjarmason, May 20, 2022
  8. Junio C HamanoMay 20, 2022
  9. 2.36 fast-export regression fixRené Scharfe, Apr 30, 2022
  10. Junio C HamanoApr 30, 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.