aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/nvim/dir.lua
diff options
context:
space:
mode:
authorMAAZIZ Adel Ayoub <adelayoub.maaziz@gmail.com>2026-07-09 21:07:17 +0100
committerGitHub <noreply@github.com>2026-07-09 16:07:17 -0400
commitde141b4679eeabba9e4ec3813547ad587039b0db (patch)
treedf38c0e6b82b1fb31e8ed64e66956596b721af6b /runtime/lua/nvim/dir.lua
parenta54a7f6a78ab0694a0cedf696bfbe4f65468164e (diff)
downloadrneovim-de141b4679eeabba9e4ec3813547ad587039b0db.tar.gz
rneovim-de141b4679eeabba9e4ec3813547ad587039b0db.tar.bz2
rneovim-de141b4679eeabba9e4ec3813547ad587039b0db.zip
fix(socket): --listen silently truncates long paths #40625
Problem: A `--listen` path longer than the system socket path limit (~104 bytes on macOS, 108 on Linux) is silently truncated by `uv_pipe_bind()`. Nvim either serves a socket at a different path than `v:servername` reports, or fails with an error that blames the full untruncated path (confusing): nvim: Failed to --listen: address already in use: "<full path>" Steps to reproduce: $ nvim --listen /var/folders/g7/9y_ydbnj2fs_fvp8xf44p8gc0000gn/T//nvim/-Users-rpatterson-Projects-src-github.com-neovide-neovide --embed -p nvim: Failed to --listen: address already in use: "/var/folders/g7/9y_ydbnj2fs_fvp8xf44p8gc0000gn/T//nvim/-Users-rpatterson-Projects-src-github.com-neovide-neovide" $ ls /var/folders/g7/9y_ydbnj2fs_fvp8xf44p8gc0000gn/T//nvim/-Users-rpatterson-Projects-src-github.com-neovide-neovide "/var/folders/g7/9y_ydbnj2fs_fvp8xf44p8gc0000gn/T//nvim/-Users-rpatterson-Projects-src-github.com-neovide-neovide": No such file or directory (os error 2) $ ls -l /var/folders/g7/9y_ydbnj2fs_fvp8xf44p8gc0000gn/T//nvim/ srwxr-xr-x@ - rpatterson 31 Mar 10:24 -Users-rpatterson-Projects-src-github.com-neovid Solution: Bind with `uv_pipe_bind2()` and `UV_PIPE_NO_TRUNCATE` (libuv 1.46+), so a too-long path fails up front with the actual reason: nvim: Failed to --listen: invalid argument: "<full path>"
Diffstat (limited to 'runtime/lua/nvim/dir.lua')
0 files changed, 0 insertions, 0 deletions