diff --git a/src/wayland/meta-wayland-xdg-shell.c b/src/wayland/meta-wayland-xdg-shell.c index 4a173d313..5548e558c 100644 --- a/src/wayland/meta-wayland-xdg-shell.c +++ b/src/wayland/meta-wayland-xdg-shell.c @@ -1590,6 +1590,15 @@ meta_wayland_xdg_surface_post_apply_state (MetaWaylandSurfaceRole *surface_role meta_wayland_shell_surface_determine_geometry (shell_surface, &pending->new_geometry, &priv->geometry); + if (priv->geometry.width == 0 || priv->geometry.height == 0) + { + g_warning ("Invalid window geometry for xdg_surface@%d. Ignoring " + "for now, but this will result in client termination " + "in the future.", + wl_resource_get_id (priv->resource)); + return; + } + priv->has_set_geometry = TRUE; } else if (!priv->has_set_geometry)