mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
patch 8.2.4399: crash after ml_get error
Problem: Crash after ml_get error. Solution: When returning "???" flush the line and set ml_line_lnum.
This commit is contained in:
parent
b31aec3b93
commit
f9435e49ef
@ -2619,9 +2619,12 @@ ml_get_buf(
|
|||||||
siemsg(_(e_ml_get_invalid_lnum_nr), lnum);
|
siemsg(_(e_ml_get_invalid_lnum_nr), lnum);
|
||||||
--recursive;
|
--recursive;
|
||||||
}
|
}
|
||||||
|
ml_flush_line(buf);
|
||||||
|
buf->b_ml.ml_flags &= ~ML_LINE_DIRTY;
|
||||||
errorret:
|
errorret:
|
||||||
STRCPY(questions, "???");
|
STRCPY(questions, "???");
|
||||||
buf->b_ml.ml_line_len = 4;
|
buf->b_ml.ml_line_len = 4;
|
||||||
|
buf->b_ml.ml_line_lnum = lnum;
|
||||||
return questions;
|
return questions;
|
||||||
}
|
}
|
||||||
if (lnum <= 0) // pretend line 0 is line 1
|
if (lnum <= 0) // pretend line 0 is line 1
|
||||||
|
@ -750,6 +750,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
4399,
|
||||||
/**/
|
/**/
|
||||||
4398,
|
4398,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user