summaryrefslogtreecommitdiff
path: root/daemon/gdm-manager.c
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2016-04-19 11:02:08 -0400
committerRay Strode <rstrode@redhat.com>2017-03-03 15:28:50 -0500
commit5c9e120594839b0597bc7bb8d06be7ba1076c0d8 (patch)
treede6dc9e55e8b7acd90216169dc067cfd3bb0b4ea /daemon/gdm-manager.c
parent1bd10fd185222a106bd4a8098d5ed6e8bc3c655e (diff)
downloadgdm-5c9e120594839b0597bc7bb8d06be7ba1076c0d8.tar.gz
manager: handle session failing to start
Right now if a session fails really early in the start up process, we fail to handle it. This commit fixes that. https://bugzilla.gnome.org/show_bug.cgi?id=779498
Diffstat (limited to 'daemon/gdm-manager.c')
-rw-r--r--daemon/gdm-manager.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/daemon/gdm-manager.c b/daemon/gdm-manager.c
index 0056079f..0cd5a918 100644
--- a/daemon/gdm-manager.c
+++ b/daemon/gdm-manager.c
@@ -1733,6 +1733,15 @@ remove_user_session (GdmManager *manager,
}
static void
+on_session_start_failed (GdmSession *session,
+ const char *service_name,
+ GdmManager *manager)
+{
+ g_debug ("GdmManager: session failed to start");
+ remove_user_session (manager, session);
+}
+
+static void
on_user_session_exited (GdmSession *session,
int code,
GdmManager *manager)
@@ -2111,6 +2120,10 @@ create_embryonic_user_session_for_display (GdmManager *manager,
G_CALLBACK (on_user_session_started),
manager);
g_signal_connect (session,
+ "session-start-failed",
+ G_CALLBACK (on_session_start_failed),
+ manager);
+ g_signal_connect (session,
"session-exited",
G_CALLBACK (on_user_session_exited),
manager);