Skip to content

Commit 25b0e6b

Browse files
committed
patch 8.0.0208: internally used commands end up in history
Problem: Internally used commands for CTRL-Z and mouse click end up in history. (Matthew Malcomson) Solution: Use do_cmdline_cmd() instead of stuffing them in the readahead buffer. (James McCoy, closes #1395)
1 parent 23c9e8b commit 25b0e6b

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

src/edit.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1025,7 +1025,7 @@ edit(
10251025
case Ctrl_Z: /* suspend when 'insertmode' set */
10261026
if (!p_im)
10271027
goto normalchar; /* insert CTRL-Z as normal char */
1028-
stuffReadbuff((char_u *)":st\r");
1028+
do_cmdline_cmd((char_u *)"stop");
10291029
c = Ctrl_O;
10301030
/*FALLTHROUGH*/
10311031

src/normal.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2982,9 +2982,9 @@ do_mouse(
29822982
if (State & INSERT)
29832983
stuffcharReadbuff(Ctrl_O);
29842984
if (curwin->w_llist_ref == NULL) /* quickfix window */
2985-
stuffReadbuff((char_u *)":.cc\n");
2985+
do_cmdline_cmd((char_u *)".cc");
29862986
else /* location list window */
2987-
stuffReadbuff((char_u *)":.ll\n");
2987+
do_cmdline_cmd((char_u *)".ll");
29882988
got_click = FALSE; /* ignore drag&release now */
29892989
}
29902990
#endif

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -764,6 +764,8 @@ static char *(features[]) =
764764

765765
static int included_patches[] =
766766
{ /* Add new patch number below this line */
767+
/**/
768+
208,
767769
/**/
768770
207,
769771
/**/

0 commit comments

Comments
 (0)