Destroy zxdg_toplevel_decoration_v1 object with toplevel
This is a protocol violation and crashes dwl. On niri it causes the toplevel to "leak".
This commit is contained in:
parent
0559ace758
commit
45c0556964
1 changed files with 4 additions and 1 deletions
|
|
@ -216,7 +216,10 @@ impl SurfaceData {
|
|||
fn destroy_role(&mut self) {
|
||||
if let Some(role) = self.role.take() {
|
||||
match role {
|
||||
SurfaceRole::Toplevel(Some(t)) => {
|
||||
SurfaceRole::Toplevel(Some(mut t)) => {
|
||||
if let Some(decoration) = t.decoration.take() {
|
||||
decoration.destroy();
|
||||
}
|
||||
t.toplevel.destroy();
|
||||
t.xdg.surface.destroy();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue