mirror of
https://github.com/tmux/tmux.git
synced 2024-11-19 19:08:50 +00:00
Check event is initialized before delete; fixes crash reported by
Michael Nickerson in GitHub issue 1068.
This commit is contained in:
parent
d8d6c2746e
commit
af2c7ce646
3
alerts.c
3
alerts.c
@ -142,7 +142,8 @@ alerts_reset(struct window *w)
|
|||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
|
|
||||||
w->flags &= ~WINDOW_SILENCE;
|
w->flags &= ~WINDOW_SILENCE;
|
||||||
event_del(&w->alerts_timer);
|
if (event_initialized(&w->alerts_timer))
|
||||||
|
event_del(&w->alerts_timer);
|
||||||
|
|
||||||
timerclear(&tv);
|
timerclear(&tv);
|
||||||
tv.tv_sec = options_get_number(w->options, "monitor-silence");
|
tv.tv_sec = options_get_number(w->options, "monitor-silence");
|
||||||
|
Loading…
Reference in New Issue
Block a user