diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-07-07 05:37:30 +0800 |
---|---|---|
committer | zeertzjq <zeertzjq@outlook.com> | 2022-07-07 07:00:11 +0800 |
commit | 0612101c92f7043e47a1b4e80120582ff538c4f8 (patch) | |
tree | 694f97141c0073c4f6017da8737f32672f7e81ea /src/nvim/buffer.c | |
parent | df4c634d067cf01adca75abb5f38989777c5cddd (diff) | |
download | rneovim-0612101c92f7043e47a1b4e80120582ff538c4f8.tar.gz rneovim-0612101c92f7043e47a1b4e80120582ff538c4f8.tar.bz2 rneovim-0612101c92f7043e47a1b4e80120582ff538c4f8.zip |
vim-patch:8.2.5043: can open a cmdline window from a substitute expression
Problem: Can open a cmdline window from a substitute expression.
Solution: Disallow opening a command line window when text or buffer is
locked.
https://github.com/vim/vim/commit/71223e2db87c2bf3b09aecb46266b56cda26191d
Diffstat (limited to 'src/nvim/buffer.c')
-rw-r--r-- | src/nvim/buffer.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c index 411705cfa3..7e1eae9632 100644 --- a/src/nvim/buffer.c +++ b/src/nvim/buffer.c @@ -1963,11 +1963,7 @@ int buflist_getfile(int n, linenr_T lnum, int options, int forceit) return OK; } - if (text_locked()) { - text_locked_msg(); - return FAIL; - } - if (curbuf_locked()) { + if (text_or_buf_locked()) { return FAIL; } |