diff options
author | Bram Moolenaar <Bram@vim.org> | 2017-12-23 17:26:11 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2017-12-23 17:26:11 +0100 |
commit | fabaf753e26df5a89a854673d14c15a1fa6b321a (patch) | |
tree | 511e8530aaaa84f9fc2bb08459f156deb2b528e7 /src/userfunc.c | |
parent | 45a0000d5c4a5ea934d5a16a2ab5bbcf307623ac (diff) | |
download | vim-git-fabaf753e26df5a89a854673d14c15a1fa6b321a.tar.gz |
patch 8.0.1423: error in return not caught by try/catchv8.0.1423
Problem: Error in return not caught by try/catch.
Solution: Call update_force_abort(). (Yasuhiro Matsomoto, closes #2483)
Diffstat (limited to 'src/userfunc.c')
-rw-r--r-- | src/userfunc.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/userfunc.c b/src/userfunc.c index 580df0bf8..931683d7c 100644 --- a/src/userfunc.c +++ b/src/userfunc.c @@ -2972,6 +2972,9 @@ ex_return(exarg_T *eap) /* It's safer to return also on error. */ else if (!eap->skip) { + /* In return statement, cause_abort should be force_abort. */ + update_force_abort(); + /* * Return unless the expression evaluation has been cancelled due to an * aborting error, an interrupt, or an exception. |