windowManager: X11 can work without gsd-xsettings

Currently, a failure to start the Systemd unit `gsd-xsettings.target`
would be considered a failure to start Xwayland.

That means that if `gsd-xsettings.target` fails to start for whatever
reason, no X11 client can be used on Wayland.

However, XSettings is by no mean mandatory for X11 clients and many
legacy X11 clients do not implement XSettings. Those who do always have
a fallback path and therefore can still work without XSettings.

Make a failure to start the Systemd unit `gsd-xsettings.target` non
blocking for Xwayland, and just log a warning message.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1065
This commit is contained in:
Olivier Fourdan 2020-03-03 13:14:23 +01:00 committed by Florian Müllner
parent 4ff94f80a0
commit a96753f085

View File

@ -903,7 +903,8 @@ var WindowManager = class {
/* Leave this watchdog timeout so don't block indefinitely here */
let timeoutId = GLib.timeout_add_seconds(GLib.PRIORITY_DEFAULT, 5, () => {
Gio.DBus.session.unwatch_name(watchId);
task.return_boolean(false);
log('Warning: Failed to start gsd-xsettings');
task.return_boolean(true);
timeoutId = 0;
return GLib.SOURCE_REMOVE;
});