From b1a63bcd84adad5bffa8ba73dbf64e05c8ce9bc9 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Fri, 17 Jan 2020 18:11:20 +0100 Subject: keyboard-group: two NULL keymaps are equal Previously, creating a keyboard group without any keymap set would result in an error: Device keymap does not match keyboard group's --- types/wlr_keyboard_group.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/types/wlr_keyboard_group.c b/types/wlr_keyboard_group.c index 144132fe..71e95646 100644 --- a/types/wlr_keyboard_group.c +++ b/types/wlr_keyboard_group.c @@ -82,6 +82,9 @@ struct wlr_keyboard_group *wlr_keyboard_group_from_wlr_keyboard( } static bool keymaps_match(struct xkb_keymap *km1, struct xkb_keymap *km2) { + if (!km1 && !km2) { + return true; + } if (!km1 || !km2) { return false; } -- cgit v1.2.3