mirror of
https://github.com/brl/mutter.git
synced 2024-11-23 00:20:42 -05:00
xwayland: Only warn on X IO errors when X11 is mandatory
This avoids warnings when we're just slightly unlucky when Xwayland went away due to inactivity. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2364>
This commit is contained in:
parent
e1033951ef
commit
bdb34401c5
@ -54,6 +54,8 @@ typedef struct
|
||||
|
||||
struct _MetaXWaylandManager
|
||||
{
|
||||
MetaWaylandCompositor *compositor;
|
||||
|
||||
MetaXWaylandConnection private_connection;
|
||||
MetaXWaylandConnection public_connection;
|
||||
|
||||
|
@ -478,7 +478,16 @@ static void
|
||||
x_io_error_exit (Display *display,
|
||||
void *data)
|
||||
{
|
||||
g_warning ("Xwayland just died, attempting to recover");
|
||||
MetaXWaylandManager *manager = data;
|
||||
MetaX11DisplayPolicy x11_display_policy;
|
||||
|
||||
x11_display_policy =
|
||||
meta_context_get_x11_display_policy (manager->compositor->context);
|
||||
|
||||
if (x11_display_policy == META_X11_DISPLAY_POLICY_MANDATORY)
|
||||
g_warning ("X Wayland crashed (X IO error)");
|
||||
else
|
||||
meta_topic (META_DEBUG_WAYLAND, "Xwayland disappeared");
|
||||
}
|
||||
|
||||
static void
|
||||
@ -1033,6 +1042,7 @@ meta_xwayland_init (MetaXWaylandManager *manager,
|
||||
manager->public_connection.name,
|
||||
manager->private_connection.name);
|
||||
|
||||
manager->compositor = compositor;
|
||||
manager->wayland_display = wl_display;
|
||||
policy = meta_context_get_x11_display_policy (context);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user