[gdm/wip/reap-greeter-on-login: 2/3] local-display-factory: ensure non-seat0 codepath doesn't affect seat0



commit 9c33d11bd3efe11b8bdb56d0fd97895547a5b06c
Author: Ray Strode <rstrode redhat com>
Date:   Fri Aug 3 16:50:36 2018 -0400

    local-display-factory: ensure non-seat0 codepath doesn't affect seat0
    
    create_display currently bails in some cases if any display is running
    on the seat.  That's the right thing to do on seats other than seat0,
    but wrong for seat0 (which an have multiple sessions at the same
    time).
    
    To ensure we never hit the case for seat0, add a call to check if
    the passed seat is multi-session capable.

 daemon/gdm-local-display-factory.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/daemon/gdm-local-display-factory.c b/daemon/gdm-local-display-factory.c
index f214185f..598a949d 100644
--- a/daemon/gdm-local-display-factory.c
+++ b/daemon/gdm-local-display-factory.c
@@ -395,7 +395,7 @@ create_display (GdmLocalDisplayFactory *factory,
                         return NULL;
                 }
                 g_clear_pointer (&active_session_id, g_free);
-        } else {
+        } else if (!sd_seat_can_multi_session (seat_id)) {
                 /* Ensure we don't create the same display more than once */
                 display = gdm_display_store_find (store, lookup_by_seat_id, (gpointer) seat_id);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]