0
0
mirror of https://github.com/vim/vim.git synced 2025-09-27 04:14:06 -04:00

patch 8.2.0614: get ml_get error when deleting a line in 'completefunc'

Problem:    Get ml_get error when deleting a line in 'completefunc'. (Yegappan
            Lakshmanan)
Solution:   Lock the text while evaluating 'completefunc'.
This commit is contained in:
Bram Moolenaar
2020-04-21 22:01:14 +02:00
parent 1966c24881
commit ff06f283e3
12 changed files with 62 additions and 42 deletions

View File

@@ -175,16 +175,10 @@ edit(
#endif
// Don't allow changes in the buffer while editing the cmdline. The
// caller of getcmdline() may get confused.
if (textlock != 0)
{
emsg(_(e_secure));
return FALSE;
}
// Don't allow recursive insert mode when busy with completion.
if (ins_compl_active() || compl_busy || pum_visible())
if (textlock != 0 || ins_compl_active() || compl_busy || pum_visible())
{
emsg(_(e_secure));
emsg(_(e_textlock));
return FALSE;
}
ins_compl_clear(); // clear stuff for CTRL-X mode