[mutter/wip/carlosg/unlink-listeners: 1/3] wayland: Ensure to unlink destroy listeners after destruction
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/carlosg/unlink-listeners: 1/3] wayland: Ensure to unlink destroy listeners after destruction
- Date: Fri, 19 Aug 2022 15:18:31 +0000 (UTC)
commit 9b8801f8b20d965b945665e38e253ee615304620
Author: Carlos Garnacho <carlosg gnome org>
Date: Fri Aug 19 17:08:42 2022 +0200
wayland: Ensure to unlink destroy listeners after destruction
This is missed in some wl_listeners added
through wl_resource_add_destroy_listener(). Ensure this is done consistently
for all notify functions.
src/wayland/meta-wayland-data-device.c | 2 ++
1 file changed, 2 insertions(+)
---
diff --git a/src/wayland/meta-wayland-data-device.c b/src/wayland/meta-wayland-data-device.c
index c8cf8f5c4b..34b3d541ba 100644
--- a/src/wayland/meta-wayland-data-device.c
+++ b/src/wayland/meta-wayland-data-device.c
@@ -178,6 +178,7 @@ destroy_drag_focus (struct wl_listener *listener, void *data)
MetaWaylandDragGrab *grab = wl_container_of (listener, grab, drag_focus_listener);
grab->drag_focus_data_device = NULL;
+ wl_list_remove (&grab->drag_focus_listener.link);
g_clear_signal_handler (&grab->drag_focus_destroy_handler_id,
grab->drag_focus);
@@ -566,6 +567,7 @@ destroy_data_device_icon (struct wl_listener *listener, void *data)
wl_container_of (listener, drag_grab, drag_icon_listener);
drag_grab->drag_surface = NULL;
+ wl_list_remove (&drag_grab->drag_icon_listener.link);
if (drag_grab->feedback_actor)
clutter_actor_remove_all_children (drag_grab->feedback_actor);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]