aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/normal.c
diff options
context:
space:
mode:
authorMagnus Groß <magnus.gross@rwth-aachen.de>2021-11-17 18:31:51 +0100
committerMagnus Groß <magnus.gross@rwth-aachen.de>2021-11-18 14:23:33 +0100
commit980c68d0362c3ca099c0facef2d08efede76aabf (patch)
tree4e72bfba16d15afbaf373103dbf5951e48f34f53 /src/nvim/normal.c
parent1fb101afe4f28ada83721c4ac260de46d23504ee (diff)
downloadrneovim-980c68d0362c3ca099c0facef2d08efede76aabf.tar.gz
rneovim-980c68d0362c3ca099c0facef2d08efede76aabf.tar.bz2
rneovim-980c68d0362c3ca099c0facef2d08efede76aabf.zip
vim-patch:8.2.3610: crash when ModeChanged triggered too early
Problem: Crash when ModeChanged triggered too early. Solution: Trigger ModeChanged after setting VIsual. https://github.com/vim/vim/commit/a062006b9de0b2947ab5fb376c6e67ef92a8cd69
Diffstat (limited to 'src/nvim/normal.c')
-rw-r--r--src/nvim/normal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/normal.c b/src/nvim/normal.c
index 686eddfb14..2ef15bde9b 100644
--- a/src/nvim/normal.c
+++ b/src/nvim/normal.c
@@ -6789,7 +6789,6 @@ static void n_start_visual_mode(int c)
VIsual_mode = c;
VIsual_active = true;
VIsual_reselect = true;
- trigger_modechanged();
// Corner case: the 0 position in a tab may change when going into
// virtualedit. Recalculate curwin->w_cursor to avoid bad highlighting.
//
@@ -6801,6 +6800,7 @@ static void n_start_visual_mode(int c)
foldAdjustVisual();
+ trigger_modechanged();
setmouse();
// Check for redraw after changing the state.
conceal_check_cursor_line();