mirror of
https://github.com/vim/vim
synced 2025-07-16 01:01:58 +00:00
patch 9.1.1474: missing out-of-memory check in mark.c
Problem: missing out-of-memory check in mark.c Solution: bail out, if mark_line() returns NULL (John Marriott) closes: #17578 Signed-off-by: John Marriott <basilisk@internode.on.net> Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
8d9d2b222d
commit
46b02602d6
@ -783,6 +783,11 @@ show_one_mark(
|
|||||||
if (name == NULL && current)
|
if (name == NULL && current)
|
||||||
{
|
{
|
||||||
name = mark_line(p, 15);
|
name = mark_line(p, 15);
|
||||||
|
if (name == NULL)
|
||||||
|
{
|
||||||
|
emsg(_(e_out_of_memory));
|
||||||
|
return;
|
||||||
|
}
|
||||||
mustfree = TRUE;
|
mustfree = TRUE;
|
||||||
}
|
}
|
||||||
if (!message_filtered(name))
|
if (!message_filtered(name))
|
||||||
|
@ -709,6 +709,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 */
|
||||||
|
/**/
|
||||||
|
1474,
|
||||||
/**/
|
/**/
|
||||||
1473,
|
1473,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user