updated for version 7.3.241 v7.3.241
authorBram Moolenaar <Bram@vim.org>
Thu, 7 Jul 2011 14:44:37 +0000 (16:44 +0200)
committerBram Moolenaar <Bram@vim.org>
Thu, 7 Jul 2011 14:44:37 +0000 (16:44 +0200)
Problem:    Using CTRL-R CTRL-W on the command line may insert only part of
            the word.
Solution:   Use the cursor position instead of assuming it is at the end of
            the command. (Tyru)

src/ex_getln.c
src/version.c

index 561ab970ee944cc1d932f6240f396667e1dbf343..913d9830eda03fef52df1c2956fd26ae5cd4e8cd 100644 (file)
@@ -3046,7 +3046,7 @@ cmdline_paste(regname, literally, remcr)
            int     len;
 
            /* Locate start of last word in the cmd buffer. */
-           for (w = ccline.cmdbuff + ccline.cmdlen; w > ccline.cmdbuff; )
+           for (w = ccline.cmdbuff + ccline.cmdpos; w > ccline.cmdbuff; )
            {
 #ifdef FEAT_MBYTE
                if (has_mbyte)
@@ -3064,7 +3064,7 @@ cmdline_paste(regname, literally, remcr)
                    --w;
                }
            }
-           len = (int)((ccline.cmdbuff + ccline.cmdlen) - w);
+           len = (int)((ccline.cmdbuff + ccline.cmdpos) - w);
            if (p_ic ? STRNICMP(w, arg, len) == 0 : STRNCMP(w, arg, len) == 0)
                p += len;
        }
index 2104c0f6a055c5ea9fd48b1b4fa6497575990541..d9b50a6500d25a971711b501ee76a42bec8c49cb 100644 (file)
@@ -709,6 +709,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    241,
 /**/
     240,
 /**/