[SCM] Vim packaging branch, deb/keywordprg, updated. upstream/7.2.010-18-gfea6630

James Vega jamessan at debian.org
Fri Oct 3 14:21:26 UTC 2008


The following commit has been merged in the deb/keywordprg branch:
commit fea6630a9f14aabaac41a2d4715649f4ebb848ee
Author: James Vega <jamessan at debian.org>
Date:   Fri Oct 3 09:46:01 2008 -0400

    strncpy the string before passing it to vim_strsave_shellescape
    
    Signed-off-by: James Vega <jamessan at debian.org>

diff --git a/src/normal.c b/src/normal.c
index 5a2efc1..785de7c 100644
--- a/src/normal.c
+++ b/src/normal.c
@@ -5519,9 +5519,11 @@ nv_ident(cap)
      */
     if (cmdchar == 'K' && !kp_help)
     {
+	/* Use only the chars in the identifier, instead of the whole line */
+	char_u s[n+1];
+	vim_strncpy(s, ptr, n);
 	/* Escape the argument properly for a shell command */
-	ptr[n] = NUL;
-	p = vim_strsave_shellescape(ptr, TRUE);
+	p = vim_strsave_shellescape(s, TRUE);
 	if (p == NULL)
 	{
 	    vim_free(buf);

-- 
Vim packaging



More information about the pkg-vim-maintainers mailing list