From a2dcb1d78737d3daa301ee63fbdd02837acb71a8 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Sun, 28 Apr 2019 11:24:15 +0200 Subject: [PATCH] logind: consider "greeter" sessions suitable as "display" sessions of a user Interestingly, elect_display_compare() already ordered "user" sessions before "greeter" sessions, though nothing other than "user" sessions where ever considered anyway. Fixes: #12399 --- src/login/logind-user.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/login/logind-user.c b/src/login/logind-user.c index c5d442865cc..05c57c1c327 100644 --- a/src/login/logind-user.c +++ b/src/login/logind-user.c @@ -663,7 +663,7 @@ static bool elect_display_filter(Session *s) { /* Return true if the session is a candidate for the user’s ‘primary session’ or ‘display’. */ assert(s); - return s->class == SESSION_USER && s->started && !s->stopping; + return IN_SET(s->class, SESSION_USER, SESSION_GREETER) && s->started && !s->stopping; } static int elect_display_compare(Session *s1, Session *s2) { -- 2.47.3