]> granicus.if.org Git - vim/commitdiff
patch 8.1.0052: when mapping to <Nop> times out the next mapping is skipped v8.1.0052
authorBram Moolenaar <Bram@vim.org>
Tue, 12 Jun 2018 19:35:40 +0000 (21:35 +0200)
committerBram Moolenaar <Bram@vim.org>
Tue, 12 Jun 2018 19:35:40 +0000 (21:35 +0200)
Problem:    When a mapping to <Nop> times out the next mapping is skipped.
Solution:   Reset "timedout" when waiting for a character. (Christian
            Brabandt, closes #2921)

src/getchar.c
src/version.c

index ff03905b442417f98388a7bca078630a3b7ae0e1..ce7508c569627649d9e81179aa85f8b5c03b8aec 100644 (file)
@@ -2856,6 +2856,11 @@ vgetorpeek(int advance)
 /*
  * get a character: 3. from the user - get it
  */
+               if (typebuf.tb_len == 0)
+                   // timedout may have been set while waiting for a mapping
+                   // that has a <Nop> RHS.
+                   timedout = FALSE;
+
                wait_tb_len = typebuf.tb_len;
                c = inchar(typebuf.tb_buf + typebuf.tb_off + typebuf.tb_len,
                        typebuf.tb_buflen - typebuf.tb_off - typebuf.tb_len - 1,
index 5ff56fdb034ef6740d77799578c60f6ef0074f10..3187cf284570c5125a965df0762290990fcbc384 100644 (file)
@@ -761,6 +761,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    52,
 /**/
     51,
 /**/