diff options
Diffstat (limited to 'sway/input')
-rw-r--r-- | sway/input/seat.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c index e7b6e0c5..ab07c03c 100644 --- a/sway/input/seat.c +++ b/sway/input/seat.c @@ -696,8 +696,14 @@ void seat_set_focus_warp(struct sway_seat *seat, config->urgent_timeout > 0) { view->urgent_timer = wl_event_loop_add_timer(server.wl_event_loop, handle_urgent_timeout, view); - wl_event_source_timer_update(view->urgent_timer, - config->urgent_timeout); + if (view->urgent_timer) { + wl_event_source_timer_update(view->urgent_timer, + config->urgent_timeout); + } else { + wlr_log(WLR_ERROR, "Unable to create urgency timer. " + "There might not be any available file descriptors."); + handle_urgent_timeout(view); + } } else { view_set_urgent(view, false); } |