aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/buffer.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-02-14 18:56:30 +0800
committerzeertzjq <zeertzjq@outlook.com>2022-02-14 18:56:30 +0800
commitdcefd48c1b7023bb1dce25bf9f6cfce47edbe993 (patch)
tree58bce3c008b9c154b93975b446c2520701dcaca4 /src/nvim/buffer.c
parentc9b46f154bfd1208310f8de931e899f562da9a95 (diff)
downloadrneovim-dcefd48c1b7023bb1dce25bf9f6cfce47edbe993.tar.gz
rneovim-dcefd48c1b7023bb1dce25bf9f6cfce47edbe993.tar.bz2
rneovim-dcefd48c1b7023bb1dce25bf9f6cfce47edbe993.zip
vim-patch:8.2.0156: various typos in source files and tests
Problem: Various typos in source files and tests. Solution: Fix the typos. (Emir Sari, closes vim/vim#5532) https://github.com/vim/vim/commit/4b96df5a017a04141c4e901b1fc5704a3ca48099
Diffstat (limited to 'src/nvim/buffer.c')
-rw-r--r--src/nvim/buffer.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c
index 38b045b31c..19e5bb69f3 100644
--- a/src/nvim/buffer.c
+++ b/src/nvim/buffer.c
@@ -1441,7 +1441,7 @@ void set_curbuf(buf_T *buf, int action)
set_bufref(&prevbufref, prevbuf);
set_bufref(&newbufref, buf);
- // Autocommands may delete the curren buffer and/or the buffer we want to go
+ // Autocommands may delete the current buffer and/or the buffer we want to go
// to. In those cases don't close the buffer.
if (!apply_autocmds(EVENT_BUFLEAVE, NULL, NULL, false, curbuf)
|| (bufref_valid(&prevbufref) && bufref_valid(&newbufref)
@@ -1454,6 +1454,7 @@ void set_curbuf(buf_T *buf, int action)
}
if (bufref_valid(&prevbufref) && !aborting()) {
win_T *previouswin = curwin;
+
// Do not sync when in Insert mode and the buffer is open in
// another window, might be a timer doing something in another
// window.