mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 8.1.2026: possibly using uninitialized memory
Problem: Possibly using uninitialized memory. Solution: Check if "dict" is NULL. (closes #4925)
This commit is contained in:
@@ -7074,12 +7074,12 @@ cursor_pos_info(dict_T *dict)
|
|||||||
}
|
}
|
||||||
|
|
||||||
bom_count = bomb_size();
|
bom_count = bomb_size();
|
||||||
if (bom_count > 0)
|
if (dict == NULL && bom_count > 0)
|
||||||
vim_snprintf((char *)IObuff + STRLEN(IObuff), IOSIZE,
|
vim_snprintf((char *)IObuff + STRLEN(IObuff), IOSIZE,
|
||||||
_("(+%lld for BOM)"), (long_long_T)bom_count);
|
_("(+%lld for BOM)"), (long_long_T)bom_count);
|
||||||
if (dict == NULL)
|
if (dict == NULL)
|
||||||
{
|
{
|
||||||
/* Don't shorten this message, the user asked for it. */
|
// Don't shorten this message, the user asked for it.
|
||||||
p = p_shm;
|
p = p_shm;
|
||||||
p_shm = (char_u *)"";
|
p_shm = (char_u *)"";
|
||||||
msg((char *)IObuff);
|
msg((char *)IObuff);
|
||||||
|
@@ -757,6 +757,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 */
|
||||||
|
/**/
|
||||||
|
2026,
|
||||||
/**/
|
/**/
|
||||||
2025,
|
2025,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user