diff --git a/video/out/wayland_common.c b/video/out/wayland_common.c index 90d4e162e4..7c5e0e6a93 100644 --- a/video/out/wayland_common.c +++ b/video/out/wayland_common.c @@ -452,7 +452,7 @@ static void keyboard_handle_key(void *data, struct wl_keyboard *wl_keyboard, } if (state == MP_KEY_STATE_DOWN) wl->mpkey = mpkey; - if (wl->mpkey == mpkey && state == MP_KEY_STATE_UP) + if (mpkey && state == MP_KEY_STATE_UP) wl->mpkey = 0; }