Skip to content

Commit 70c4344

Browse files
Sunderland93mtwebster
authored andcommitted
wayland/xdg-shell: Bail from popup_configure if resource was destroyed
This function gets called when a surface state transaction is applied. Applying a transaction can get delayed, so the Wayland resource may have already been destroyed when we get here. In that case we cannot send events, so there's nothing to do.
1 parent 2b0e18c commit 70c4344

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/wayland/meta-wayland-xdg-shell.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1286,6 +1286,9 @@ meta_wayland_xdg_popup_configure (MetaWaylandShellSurface *shell_surface,
12861286
int geometry_scale;
12871287
int x, y;
12881288

1289+
if (!xdg_popup->resource)
1290+
return;
1291+
12891292
/* If the parent surface was destroyed, its window will be destroyed
12901293
* before the popup receives the parent-destroy signal. This means that
12911294
* the popup may potentially get temporary focus until itself is destroyed.

0 commit comments

Comments
 (0)