vim-patch:9.1.0035: i_CTRL-] triggers InsertCharPre (#27049)

* vim-patch:9.1.0035: i_CTRL-] triggers InsertCharPre

Problem:  i_CTRL-] triggers InsertCharPre
Solution: Return if CTRL-] is received. InsertCharPre
          is supposed to be only used for chars to be inserted
          but i_CTRL-] triggers expansion and is not inserted
          into the buffer (altermo)

closes: vim/vim#13853
closes: vim/vim#13864

7d711fe209
This commit is contained in:
altermo
2024-01-17 00:35:32 +01:00
committed by GitHub
parent aa5819f5a5
commit da541c0af1
2 changed files with 38 additions and 0 deletions

View File

@@ -4725,6 +4725,10 @@ static char *do_insert_char_pre(int c)
char buf[MB_MAXBYTES + 1];
const int save_State = State;
if (c == Ctrl_RSB) {
return NULL;
}
// Return quickly when there is nothing to do.
if (!has_event(EVENT_INSERTCHARPRE)) {
return NULL;