GNOME Bugzilla – Bug 696266
fix checks for logind
Last modified: 2013-03-29 10:07:57 UTC
Many parts of gdm want to talk to logind, but actually check for systemd with sd_booted(). It is possible to build systemd without logind, in which case sd_booted() would still succeed (sd_booted() was recently fixed upstream to only be true if systemd init is active [1]). For running systemd init without logind, or for running logind without systemd init we need to change the check to test for logind for the parts that deal with session/user/seat tracking. The logging parts talk to journald, for which sd_booted() is fine. For details, see [2] if you are interested. [1] http://cgit.freedesktop.org/systemd/systemd/commit/?id=66e411811b8090 [2] https://mail.gnome.org/archives/desktop-devel-list/2013-March/msg00092.html
Created attachment 239450 [details] [review] Fix checks for logind Unlike the changes to the other GNOME modules this one is quite large, so I'd appreciate a second pair of eyes. Thanks!
Review of attachment 239450 [details] [review]: Generally looks ok, but the commit message seems to cloud the actual issue that is being addressed here. You are using logind without systemd, not systemd without logind - right ?
> You are using logind without systemd, not systemd without logind - right ? That's right, yes. In the current systemd versions the sd_booted() check is true in that mode, so we can currently do that. However, it's not really intended that way, that's why I asked Lennart to fix sd_booted() to actually mean "init", and rather fix all consumers of this; once that gets released, it will affect the "logind without systemd init case" as well, right. The worse problem is with said mode -- building systemd without logind. sd_booted() is True, but logind is not available and thus gdm is talking into the void. That doesn't directly affect Ubuntu, but it might affect other people. I'm not wedded to the commit message, of course. How about something like "It is possible to build systemd without logind or run logind without system init, in both cases testing for systemd init is wrong."?
sure, that's fine.
Created attachment 239665 [details] [review] Fix checks for logind Updated changelog.
Review of attachment 239665 [details] [review]: ok
Comment on attachment 239665 [details] [review] Fix checks for logind Pushed to master. There is no gnome-3-8 branch yet, so I assume this is sufficient for going into 3.8.1.