0
0
mirror of https://github.com/vim/vim.git synced 2025-07-26 11:04:33 -04:00

patch 7.4.1914

Problem:    Executing autocommands while using the signal stack has a high
            chance of crashing Vim.
Solution:   Don't invoke autocommands when on the signal stack.
This commit is contained in:
Bram Moolenaar 2016-06-10 19:49:14 +02:00
parent 1610d05241
commit e429e70f05
2 changed files with 10 additions and 0 deletions

View File

@ -1090,6 +1090,12 @@ deathtrap SIGDEFARG(sigarg)
/* Remember how often we have been called. */
++entered;
#ifdef FEAT_AUTOCMD
/* Executing autocommands is likely to use more stack space than we have
* available in the signal stack. */
block_autocmds();
#endif
#ifdef FEAT_EVAL
/* Set the v:dying variable. */
set_vim_var_nr(VV_DYING, (long)entered);
@ -1171,6 +1177,8 @@ deathtrap SIGDEFARG(sigarg)
* calling free(). */
preserve_exit();
/* NOTREACHED */
#ifdef NBDEBUG
reset_signals();
may_core_dump();

View File

@ -753,6 +753,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1914,
/**/
1913,
/**/