From a4ce5e08abf9fd0452965c36832b6f070a38f355 Mon Sep 17 00:00:00 2001 From: ARDiDo <90479315+ARDiDo@users.noreply.github.com> Date: Wed, 15 Sep 2021 18:34:26 -0400 Subject: [PATCH] fix no xwayland --- dwl.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/dwl.c b/dwl.c index d005906..128be93 100644 --- a/dwl.c +++ b/dwl.c @@ -1048,16 +1048,14 @@ destroynotify(struct wl_listener *listener, void *data) wl_list_remove(&c->map.link); wl_list_remove(&c->unmap.link); wl_list_remove(&c->destroy.link); - if (c->type && c->type != XDGShell) { + if (client_is_unmanaged(c)) { #ifdef XWAYLAND - if (c->type == X11Managed) { - wl_list_remove(&c->activate.link); - wl_list_remove(&c->configure.link); - } else { - wl_list_remove(&c->configure.link); - free(c); - return; - } + wl_list_remove(&c->configure.link); + free(c); + return; + } else if (c->type == X11Managed) { + wl_list_remove(&c->activate.link); + wl_list_remove(&c->configure.link); #endif } else { wl_list_remove(&c->commit.link);