diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-09-13 12:36:57 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-09-13 12:36:57 +0100 |
commit | b1842de5ca77205993e8ef76cf29803822e0e3ab (patch) | |
tree | 1d6fccbe924d8056a03df859834979fbef7dca95 /src/debugger.c | |
parent | 5ed391708a62b4ebaa84dd23e32a416e5c3383d9 (diff) |
patch 9.0.0456: function called at debug prompt is also debuggedv9.0.0456
Problem: Function called at debug prompt is also debugged.
Solution: Reset the debug level while entering the debug command.
(closes #11118)
Diffstat (limited to 'src/debugger.c')
-rw-r--r-- | src/debugger.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/debugger.c b/src/debugger.c index e2f73cca03..235d493d58 100644 --- a/src/debugger.c +++ b/src/debugger.c @@ -135,9 +135,14 @@ do_debug(char_u *cmd) ignore_script = TRUE; } + // don't debug any function call, e.g. from an expresion mapping + n = debug_break_level; + debug_break_level = -1; + vim_free(cmdline); cmdline = getcmdline_prompt('>', NULL, 0, EXPAND_NOTHING, NULL); + debug_break_level = n; if (typeahead_saved) { restore_typeahead(&typeaheadbuf, TRUE); |