mirror of
https://github.com/brl/mutter.git
synced 2024-11-23 00:20:42 -05:00
wayland/xdg-shell: Ignore reposition if popup was dismissed
If the popup was dismissed (i.e. has no MetaWindow anymore), it'll also have no parent surface. With no parent surface, we'd try to fetch a transaction from NULL and crash, but if we don't try if we were dismissed, we won't reach here anyway. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2940>
This commit is contained in:
parent
f744acefee
commit
697b99ee13
@ -642,6 +642,9 @@ xdg_popup_reposition (struct wl_client *client,
|
|||||||
MetaWaylandXdgPositioner *xdg_positioner;
|
MetaWaylandXdgPositioner *xdg_positioner;
|
||||||
MetaWaylandTransaction *transaction;
|
MetaWaylandTransaction *transaction;
|
||||||
|
|
||||||
|
if (!meta_wayland_surface_get_window (surface))
|
||||||
|
return;
|
||||||
|
|
||||||
xdg_positioner = g_memdup2 (wl_resource_get_user_data (positioner_resource),
|
xdg_positioner = g_memdup2 (wl_resource_get_user_data (positioner_resource),
|
||||||
sizeof (MetaWaylandXdgPositioner));
|
sizeof (MetaWaylandXdgPositioner));
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user