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

Re: [PATCH v2] t5564: use a short path for the SOCKS proxy socket

From
Jeff King <peff@peff.net>
Date
May 1, 2026, 06:47 UTC
Message-ID
<20260501064746.GC2038915@coredump.intra.peff.net>
In-Reply-To
<pull.2100.v2.git.1777450974159.gitgitgadget@gmail.com>
On Wed, Apr 29, 2026 at 08:22:54AM +0000, Johannes Schindelin via GitGitGadget wrote:
Show 19 quoted lines
> From: Johannes Schindelin <johannes.schindelin@gmx.de>
> 
> The SOCKS proxy test introduced in 0ca365c2ed4 (http: do not ignore
> proxy path, 2024-08-02) creates a Unix domain socket in
> `$TRASH_DIRECTORY`. When the trash directory path is long (e.g.
> when running from a deeply nested worktree), the socket path can
> exceed the 108-character limit for `struct sockaddr_un.sun_path` on
> Linux, causing the test to fail with "Path length ... is longer
> than maximum supported length (108)".
> 
> We cannot work around this using the chdir trick our own socket code
> employs, because both sides of the connection are outside our control:
> the socket is created by socks4-proxy.pl via Perl's IO::Socket::UNIX,
> and the client side is libcurl.
> 
> Use `mktemp -d` to create a unique temporary directory with a short
> path, and place the socket inside it. This avoids collisions between
> concurrent test runs (e.g. `--stress`) and tmpdir-race vulnerabilities
> that a static `/tmp` path would be susceptible to.

Thanks, this looks great to me (and thank you for fleshing out the explanation in the commit message, too).

-Peff
Previous: Johannes Schindelin via GitGitGadget
Message 4 of 4 in “t5564: use a short path for the SOCKS proxy socket”
  1. t5564: use a short path for the SOCKS proxy socketJohannes Schindelin via GitGitGadget, Apr 27, 2026
  2. Jeff KingApr 28, 2026
  3. t5564: use a short path for the SOCKS proxy socketJohannes Schindelin via GitGitGadget, Apr 29, 2026
  4. Jeff KingMay 1, 2026

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.