mirror of
https://github.com/vim/vim.git
synced 2025-09-29 04:34:16 -04:00
patch 9.0.0682: crash when popup with deleted timer is closed
Problem: Crash when popup with deleted timer is closed. (Igbanam Ogbuluijah) Solution: Check the timer still exists. (closes #11301)
This commit is contained in:
@@ -5322,7 +5322,8 @@ win_free_popup(win_T *win)
|
||||
close_buffer(win, win->w_buffer, 0, FALSE, FALSE);
|
||||
}
|
||||
# if defined(FEAT_TIMERS)
|
||||
if (win->w_popup_timer != NULL)
|
||||
// the timer may have been cleared, making the pointer invalid
|
||||
if (timer_valid(win->w_popup_timer))
|
||||
stop_timer(win->w_popup_timer);
|
||||
# endif
|
||||
vim_free(win->w_frame);
|
||||
|
Reference in New Issue
Block a user