diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-01-07 20:59:34 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-01-07 20:59:34 +0100 |
commit | e31ee86859528a7ffe00405645547d494e522fa8 (patch) | |
tree | 741c24aea3fae5efb613d64314a6721d6cad85c5 /src/buffer.c | |
parent | ce6db0273f2c4359f48d75103a42991aa481f14e (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/buffer.c')
-rw-r--r-- | src/buffer.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/buffer.c b/src/buffer.c index 0a68d484e5..f56ff0b625 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5287,6 +5287,7 @@ chk_modeline( #ifdef FEAT_EVAL sctx_T save_current_sctx; #endif + ESTACK_CHECK_DECLARATION prev = -1; for (s = ml_get(lnum); *s != NUL; ++s) @@ -5330,6 +5331,7 @@ chk_modeline( // prepare for emsg() estack_push(ETYPE_MODELINE, (char_u *)"modelines", lnum); + ESTACK_CHECK_SETUP end = FALSE; while (end == FALSE) @@ -5390,6 +5392,7 @@ chk_modeline( s = e + 1; // advance to next part } + ESTACK_CHECK_NOW estack_pop(); vim_free(linecopy); } |