From 53007eaa7d4ec3cb5b9e56041c832302577e26c1 Mon Sep 17 00:00:00 2001 From: Berke Güzel Date: Mon, 12 Oct 2026 11:29:26 +0300 Subject: wayland: destroy tablet pad group proxies Pad groups arrive as new objects with the group event. yasl ignored them, so the proxies were never destroyed and leaked on every pad. Destroy each group when it arrives. Co-Authored-By: Claude Haiku 5.5 --- src/wayland/pointer.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/wayland/pointer.c') diff --git a/src/wayland/pointer.c b/src/wayland/pointer.c index 3341d35..5924eb1 100644 --- a/src/wayland/pointer.c +++ b/src/wayland/pointer.c @@ -948,7 +948,9 @@ static const struct zwp_tablet_v2_listener tablet_listener = { .done = tablet_done, .removed = tablet_removed, .bustype = tablet_bustype, }; -static void tablet_pad_group(void *data, struct zwp_tablet_pad_v2 *pad, struct zwp_tablet_pad_group_v2 *group) { (void)data; (void)pad; (void)group; } +/* yasl does not use pad groups. The group proxy belongs to the client, so + * destroy it here rather than leak it. */ +static void tablet_pad_group(void *data, struct zwp_tablet_pad_v2 *pad, struct zwp_tablet_pad_group_v2 *group) { (void)data; (void)pad; zwp_tablet_pad_group_v2_destroy(group); } static void tablet_pad_path(void *data, struct zwp_tablet_pad_v2 *pad, const char *path) { (void)data; (void)pad; (void)path; } static void tablet_pad_buttons(void *data, struct zwp_tablet_pad_v2 *pad, uint32_t buttons) { (void)data; (void)pad; (void)buttons; } static void tablet_pad_done(void *data, struct zwp_tablet_pad_v2 *pad) { (void)data; (void)pad; } -- cgit v1.2.3