]> git.ipfire.org Git - thirdparty/vim.git/commit
runtime(zip): escape '[' on Unix as well
authorzeertzjq <zeertzjq@outlook.com>
Sun, 4 Aug 2024 16:35:50 +0000 (18:35 +0200)
committerChristian Brabandt <cb@256bit.org>
Sun, 4 Aug 2024 16:35:50 +0000 (18:35 +0200)
commitc5bdd66558b14f04424a22d9714a9b7d0c277dac
treecfe80648d3954b700cd97ee13a33a7b991df1b62
parent2708afa640907ad8ace2351c35d5c5a411dc97da
runtime(zip): escape '[' on Unix as well

Problem:  After 6f1cbfc9ab483a09877e153ad130164875c40b1d fnameescape()
          is no longer called on the name of the file to be extracted.
          However, while spaces indeed don't need to be escaped, unzip
          treats '[' as a wildcard character, so it need to be escaped.
Solution: Escape '[' on both MS-Windows and Unix.

From the docs it seems '*' and '?' also need escaping, but they seem to
actually work without escaping.

fixes: neovim/neovim#29977
closes: #15427

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
runtime/autoload/zip.vim