Skip to content

Commit

Permalink
xwayland: fix double wl_list_remove
Browse files Browse the repository at this point in the history
When destroying an xwayland surface, the dissociate and destroy handlers
are called, but both of these were removing the map and unmap signal
handlers, causing a segfault when the destroy handler went to remove
them.
Fixes #309
  • Loading branch information
Supreeeme authored and emersion committed Feb 12, 2024
1 parent 8a00921 commit b6f8f92
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions xwayland.c
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,6 @@ handle_xwayland_surface_destroy(struct wl_listener *listener, void *data)
struct cg_xwayland_view *xwayland_view = wl_container_of(listener, xwayland_view, destroy);
struct cg_view *view = &xwayland_view->view;

wl_list_remove(&xwayland_view->map.link);
wl_list_remove(&xwayland_view->unmap.link);
wl_list_remove(&xwayland_view->destroy.link);
wl_list_remove(&xwayland_view->request_fullscreen.link);
xwayland_view->xwayland_surface = NULL;
Expand Down

0 comments on commit b6f8f92

Please sign in to comment.