mirror of
https://github.com/vim/vim.git
synced 2025-09-26 04:04:07 -04:00
patch 8.2.3171: another illegal memory access in test
Problem: Another illegal memory access in test. Solution: Check pointer is after the start of the line.
This commit is contained in:
@@ -875,7 +875,7 @@ get_function_body(
|
|||||||
--end;
|
--end;
|
||||||
while (end > p && VIM_ISWHITE(*end))
|
while (end > p && VIM_ISWHITE(*end))
|
||||||
--end;
|
--end;
|
||||||
if (end > p - 2 && end[-1] == '=' && end[0] == '>')
|
if (end > p + 2 && end[-1] == '=' && end[0] == '>')
|
||||||
{
|
{
|
||||||
// found trailing "=> {", start of an inline function
|
// found trailing "=> {", start of an inline function
|
||||||
if (nesting == MAX_FUNC_NESTING - 1)
|
if (nesting == MAX_FUNC_NESTING - 1)
|
||||||
|
@@ -755,6 +755,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 */
|
||||||
|
/**/
|
||||||
|
3171,
|
||||||
/**/
|
/**/
|
||||||
3170,
|
3170,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user