mirror of
https://github.com/neovim/neovim.git
synced 2025-09-12 14:28:18 +00:00
vim-patch:7.4.2362
Problem: Illegal memory access with ":1@". (Dominique Pelle)
Solution: Correct cursor column after setting the line number. Also avoid
calling end_visual_mode() when not in Visual mode.
4930a76a03
This commit is contained in:
@@ -441,7 +441,7 @@ void close_buffer(win_T *win, buf_T *buf, int action, int abort_if_last)
|
|||||||
|
|
||||||
// When closing the current buffer stop Visual mode before freeing
|
// When closing the current buffer stop Visual mode before freeing
|
||||||
// anything.
|
// anything.
|
||||||
if (is_curbuf) {
|
if (is_curbuf && VIsual_active) {
|
||||||
end_visual_mode();
|
end_visual_mode();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1083,7 +1083,7 @@ do_buffer (
|
|||||||
}
|
}
|
||||||
|
|
||||||
// When closing the current buffer stop Visual mode.
|
// When closing the current buffer stop Visual mode.
|
||||||
if (buf == curbuf) {
|
if (buf == curbuf && VIsual_active) {
|
||||||
end_visual_mode();
|
end_visual_mode();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -7325,6 +7325,7 @@ static void ex_at(exarg_T *eap)
|
|||||||
int prev_len = typebuf.tb_len;
|
int prev_len = typebuf.tb_len;
|
||||||
|
|
||||||
curwin->w_cursor.lnum = eap->line2;
|
curwin->w_cursor.lnum = eap->line2;
|
||||||
|
check_cursor_col();
|
||||||
|
|
||||||
// Get the register name. No name means use the previous one.
|
// Get the register name. No name means use the previous one.
|
||||||
int c = *eap->arg;
|
int c = *eap->arg;
|
||||||
|
@@ -79,7 +79,7 @@ static int included_patches[] = {
|
|||||||
// 2365 NA
|
// 2365 NA
|
||||||
// 2364,
|
// 2364,
|
||||||
// 2363 NA
|
// 2363 NA
|
||||||
// 2362,
|
2362,
|
||||||
// 2361 NA
|
// 2361 NA
|
||||||
// 2360,
|
// 2360,
|
||||||
// 2359 NA
|
// 2359 NA
|
||||||
|
Reference in New Issue
Block a user