screen not locked with xscreensaver when lid is closed
When the lid is closed and Xfce is set to do lock screen, screen is not locked if xscreensaver-5.45 or newer is used. Instead error message "unable to find lock program" (or similar wording) is displayed.
It seems the following happens:
- xscreensaver provides xscreensaver-systemd daemon which is started from the .xsession. The daemon registers on the D-Bus as FreeDesktop screensaver. It supports 'Inhibit' and 'UnInhibit' methods, but it seems it doesn't support the 'Lock' method.
- xfce4-session detects FreeDesktop compatible screensaver
- lid is closed
- xfce4-session calls the 'Lock' methods through the D-Bus
- the call fails
- xfce4-session reports error
I reported the problem to the xscreensaver upstream. It seems the xscreensaver-6.00 is also affected.
I think xfce4-session should fallback to the xflock4 command in case the D-Bus call fails. Or it should try first the 'LockCommand' from the xfce4 settings if it is set. It seems the 'LockCommand' settings is completely ignored if FreeDesktop is detected.
xfce4-session-4.14.2 xscreensaver-5.45 xorg-x11-server-Xorg-1.20.11