mirror of
https://github.com/vim/vim.git
synced 2025-09-29 04:34:16 -04:00
patch 8.0.1109: timer causes error on exit from Ex mode
Problem: Timer causes error on exit from Ex mode. (xtal8) Solution: save and restore the ex_pressedreturn flag. (Christian Brabandt, closes #2079)
This commit is contained in:
@@ -1224,6 +1224,7 @@ check_due_timer(void)
|
||||
int save_must_redraw = must_redraw;
|
||||
int save_trylevel = trylevel;
|
||||
int save_did_throw = did_throw;
|
||||
int save_ex_pressedreturn = get_pressedreturn();
|
||||
except_T *save_current_exception = current_exception;
|
||||
|
||||
/* Create a scope for running the timer callback, ignoring most of
|
||||
@@ -1257,6 +1258,7 @@ check_due_timer(void)
|
||||
need_update_screen = TRUE;
|
||||
must_redraw = must_redraw > save_must_redraw
|
||||
? must_redraw : save_must_redraw;
|
||||
set_pressedreturn(save_ex_pressedreturn);
|
||||
|
||||
/* Only fire the timer again if it repeats and stop_timer() wasn't
|
||||
* called while inside the callback (tr_id == -1). */
|
||||
|
Reference in New Issue
Block a user