diff --git a/src/wayland/meta-wayland-surface.c b/src/wayland/meta-wayland-surface.c index ebf0c52f9..15c94ea9a 100644 --- a/src/wayland/meta-wayland-surface.c +++ b/src/wayland/meta-wayland-surface.c @@ -646,18 +646,9 @@ meta_wayland_surface_create (MetaWaylandCompositor *compositor, static void destroy_surface_extension (MetaWaylandSurfaceExtension *extension) { - wl_list_remove (&extension->surface_destroy_listener.link); extension->resource = NULL; } -static void -extension_handle_surface_destroy (struct wl_listener *listener, - void *data) -{ - MetaWaylandSurfaceExtension *extension = wl_container_of (listener, extension, surface_destroy_listener); - wl_resource_destroy (extension->resource); -} - static int get_resource_version (struct wl_resource *master_resource, int max_version) @@ -684,9 +675,6 @@ create_surface_extension (MetaWaylandSurfaceExtension *extension, extension->resource = wl_resource_create (client, interface, get_resource_version (master_resource, max_version), id); wl_resource_set_implementation (extension->resource, implementation, surface, destructor); - extension->surface_destroy_listener.notify = extension_handle_surface_destroy; - wl_resource_add_destroy_listener (surface->resource, &extension->surface_destroy_listener); - return TRUE; } diff --git a/src/wayland/meta-wayland-surface.h b/src/wayland/meta-wayland-surface.h index e0203f58c..ef9ccaa4f 100644 --- a/src/wayland/meta-wayland-surface.h +++ b/src/wayland/meta-wayland-surface.h @@ -75,7 +75,6 @@ typedef struct typedef struct { struct wl_resource *resource; - struct wl_listener surface_destroy_listener; } MetaWaylandSurfaceExtension; struct _MetaWaylandSurface