You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-31 18:41:20 +00:00
Wayland: Fix SIGFPE with repeat rate of 0
We always divided by the rate, which could be zero, which is a valid value (it means "disable key repeating").
This commit is contained in:
@@ -2295,7 +2295,7 @@ void WaylandThread::_wl_keyboard_on_repeat_info(void *data, struct wl_keyboard *
|
||||
SeatState *ss = (SeatState *)data;
|
||||
ERR_FAIL_NULL(ss);
|
||||
|
||||
ss->repeat_key_delay_msec = 1000 / rate;
|
||||
ss->repeat_key_delay_msec = rate ? 1000 / rate : 0;
|
||||
ss->repeat_start_delay_msec = delay;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user