summaryrefslogtreecommitdiffstats
path: root/src/autocmd.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-01-07 20:59:34 +0100
committerBram Moolenaar <Bram@vim.org>2020-01-07 20:59:34 +0100
commite31ee86859528a7ffe00405645547d494e522fa8 (patch)
tree741c24aea3fae5efb613d64314a6721d6cad85c5 /src/autocmd.c
parentce6db0273f2c4359f48d75103a42991aa481f14e (diff)
patch 8.2.0098: exe stack length can be wrong without being detectedv8.2.0098
Problem: Exe stack length can be wrong without being detected. Solution: Add a check when ABORT_ON_INTERNAL_ERROR is defined.
Diffstat (limited to 'src/autocmd.c')
-rw-r--r--src/autocmd.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/autocmd.c b/src/autocmd.c
index 983a155c60..13aa065ec8 100644
--- a/src/autocmd.c
+++ b/src/autocmd.c
@@ -1827,6 +1827,7 @@ apply_autocmds_group(
int did_save_redobuff = FALSE;
save_redo_T save_redo;
int save_KeyTyped = KeyTyped;
+ ESTACK_CHECK_DECLARATION
/*
* Quickly return if there are no autocommands for this event or
@@ -2021,6 +2022,7 @@ apply_autocmds_group(
// name and lnum are filled in later
estack_push(ETYPE_AUCMD, NULL, 0);
+ ESTACK_CHECK_SETUP
#ifdef FEAT_EVAL
save_current_sctx = current_sctx;
@@ -2124,6 +2126,7 @@ apply_autocmds_group(
filechangeshell_busy = FALSE;
autocmd_nested = save_autocmd_nested;
vim_free(SOURCING_NAME);
+ ESTACK_CHECK_NOW
estack_pop();
vim_free(autocmd_fname);
autocmd_fname = save_autocmd_fname;