vim-patch:7.4.191

Problem:    Escaping a file name for shell commands can't be done without a
            function.
Solution:   Add the :S file name modifier.

https://code.google.com/p/vim/source/detail?r=40f18a1c1592c8b4047f6f2a413557f48a99c55f
This commit is contained in:
oni-link
2014-04-12 23:04:49 +02:00
committed by Thiago de Arruda
parent 644ccdafe0
commit a881273dad
8 changed files with 95 additions and 14 deletions

View File

@@ -4493,12 +4493,8 @@ static void nv_ident(cmdarg_T *cap)
if (cmdchar == 'K' && !kp_help) {
/* Escape the argument properly for a shell command */
ptr = vim_strnsave(ptr, n);
p = vim_strsave_shellescape(ptr, TRUE);
p = vim_strsave_shellescape(ptr, true, true);
vim_free(ptr);
if (p == NULL) {
vim_free(buf);
return;
}
newbuf = (char_u *)xrealloc(buf, STRLEN(buf) + STRLEN(p) + 1);
buf = newbuf;
STRCAT(buf, p);