[gdm/wip/xserver-in-session: 15/19] session: start login screen using gdm-x-session wrapper



commit ce7f4b8c1bbfcf497b2c39e7cc0bdd8e0d5ba85c
Author: Ray Strode <rstrode redhat com>
Date:   Fri Jan 23 13:59:14 2015 -0500

    session: start login screen using gdm-x-session wrapper
    
    Since we have the wrapper, let's use it for the login screen
    to and get rid of GdmServer.

 daemon/gdm-session.c |   18 +++++++++++++-----
 1 files changed, 13 insertions(+), 5 deletions(-)
---
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
index fb1e0f0..93be389 100644
--- a/daemon/gdm-session.c
+++ b/daemon/gdm-session.c
@@ -2650,7 +2650,16 @@ gdm_session_start_session (GdmSession *self,
 
                 g_free (command);
         } else {
-                program = g_strdup (self->priv->selected_program);
+                GdmSessionDisplayMode display_mode;
+
+                display_mode = gdm_session_get_display_mode (self);
+
+                if (display_mode == GDM_SESSION_DISPLAY_MODE_LOGIND_MANAGED) {
+                        program = g_strdup_printf (LIBEXECDIR "/gdm-x-session \"%s\"",
+                                                   self->priv->selected_program);
+                } else {
+                        program = g_strdup (self->priv->selected_program);
+                }
         }
 
         set_up_session_environment (self);
@@ -2950,12 +2959,11 @@ gdm_session_get_display_mode (GdmSession *self)
                 return GDM_SESSION_DISPLAY_MODE_REUSE_VT;
         }
 
-        /* The X session used for the login screen uses the
-         * X server started up by the slave, so it should be
-         * reuse VT
+        /* The X session used for the login screen is created
+         * implicitly now and managed by logind.
          */
         if (self->priv->is_program_session) {
-                return GDM_SESSION_DISPLAY_MODE_REUSE_VT;
+                return GDM_SESSION_DISPLAY_MODE_LOGIND_MANAGED;
         }
 
         /* user based X sessions start on a new VT now and are managed


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