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

Re: [PATCH v6 1/5] difftool: create a tmpdir path without repeated slashes

From
Junio C Hamano <gitster@pobox.com>
Date
Sep 30, 2021, 21:45 UTC
Message-ID
<xmqqee95agbg.fsf@gitster.g>
In-Reply-To
<20210930170146.61489-1-davvid@gmail.com>
David Aguilar <davvid@gmail.com> writes:
Show 17 quoted lines
> The paths generated by difftool are passed to user-facing diff tools.
> Using paths with repeated slashes in them is a cosmetic blemish that
> is exposed to users and can be avoided.
>
> Use a strbuf to create the buffer used for the dir-diff tmpdir.
> Strip trailing slashes from the value read from TMPDIR to avoid
> repeated slashes in the generated paths.
>
> Adjust the error handling to avoid leaking strbufs.
>
> Signed-off-by: David Aguilar <davvid@gmail.com>
> ---
> This patch is a resend based off of "next" so that this series can be
> tracked together.
>
> This patch is unchanged since the v5 was submitted, but there are
> new related patches that proceed it.
OK.  I confirmed that this is unchanged from the first step of v5.
Previous: David Aguilar
Message 11 of 11 in “difftool: create a tmpdir path without repeated slashes”
  1. 1/5 difftool: create a tmpdir path without repeated slashesDavid Aguilar, Sep 30, 2021
  2. 2/5 difftool: add a missing space to the run_dir_diff() commentsDavid Aguilar, Sep 30, 2021
  3. 3/5 difftool: avoid returning -1 to cmd_main() from run_dir_diff()David Aguilar, Sep 30, 2021
  4. Junio C HamanoSep 30, 2021
  5. David AguilarSep 30, 2021
  6. Junio C HamanoOct 1, 2021
  7. 4/5 difftool: refactor dir-diff to write files using a helper functionDavid Aguilar, Sep 30, 2021
  8. Junio C HamanoSep 30, 2021
  9. David AguilarSep 30, 2021
  10. 5/5 difftool: remove an unnecessary call to strbuf_release()David Aguilar, Sep 30, 2021
  11. Junio C HamanoSep 30, 2021

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.