aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/fold.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-05-21 21:41:12 +0800
committerzeertzjq <zeertzjq@outlook.com>2022-05-22 06:41:31 +0800
commita1df7c5771aec0a52ed86bf89277372a1a2e4b37 (patch)
treed40354435c4c8114a3d9d38711e374ff990f2835 /src/nvim/fold.c
parent1f1a65a9e4c602cd80458b213c28eadbdb5b1de1 (diff)
downloadrneovim-a1df7c5771aec0a52ed86bf89277372a1a2e4b37.tar.gz
rneovim-a1df7c5771aec0a52ed86bf89277372a1a2e4b37.tar.bz2
rneovim-a1df7c5771aec0a52ed86bf89277372a1a2e4b37.zip
vim-patch:8.1.0535: increment/decrement might get interrupted by updating folds
Problem: Increment/decrement might get interrupted by updating folds. Solution: Disable fold updating for a moment. (Christian Brabandt, closes vim/vim#3599) https://github.com/vim/vim/commit/6b731886ca94d66b9bdedfb7e603af44a6400399
Diffstat (limited to 'src/nvim/fold.c')
-rw-r--r--src/nvim/fold.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/fold.c b/src/nvim/fold.c
index 090f754e93..2de1b8b0f9 100644
--- a/src/nvim/fold.c
+++ b/src/nvim/fold.c
@@ -775,7 +775,7 @@ void clearFolding(win_T *win)
/// The changes in lines from top to bot (inclusive).
void foldUpdate(win_T *wp, linenr_T top, linenr_T bot)
{
- if (compl_busy || State & MODE_INSERT) {
+ if (disable_fold_update || compl_busy || State & MODE_INSERT) {
return;
}