From 9e20871c3cf47b556b21ec4d41ba9b77ec72a5f4 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Sun, 23 Jun 2019 16:37:23 +0200 Subject: [PATCH] (Wayland) Buildfix --- input/drivers/wayland_input.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/input/drivers/wayland_input.c b/input/drivers/wayland_input.c index f4c00447fd..8b5218e291 100644 --- a/input/drivers/wayland_input.c +++ b/input/drivers/wayland_input.c @@ -294,11 +294,15 @@ static int16_t input_wl_state(void *data, case RETRO_DEVICE_JOYPAD: if (id == RETRO_DEVICE_ID_JOYPAD_MASK) { - bool res = BIT_GET(wl->key_state, rarch_keysym_lut[binds[port][i].key]) ; - if (!res && binds[port]) - res = input_joypad_pressed(wl->joypad, joypad_info, port, binds[port], i); - if (res) - ret |= (1 << i); + unsigned i; + for (i = 0; i < RARCH_FIRST_CUSTOM_BIND; i++) + { + bool res = BIT_GET(wl->key_state, rarch_keysym_lut[binds[port][i].key]) ; + if (!res && binds[port]) + res = input_joypad_pressed(wl->joypad, joypad_info, port, binds[port], i); + if (res) + ret |= (1 << i); + } } else {