diff options
author | Ray Strode <rstrode@redhat.com> | 2012-11-30 12:43:54 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2012-11-30 19:31:08 -0500 |
commit | e336a554a71a994c313fb5297a7b9c023fa1f8a9 (patch) | |
tree | ea684b843dba95a60f6f549933c7c3d95413dd40 | |
parent | 4ea45b77446bfa6d492f88984b4729fd8f9f32c7 (diff) | |
download | gdm-e336a554a71a994c313fb5297a7b9c023fa1f8a9.tar.gz |
slave: cancel start session request if slave gets stopped
If the slave gets stopped right before we start the user's session,
then we'll have a queued start session in flight, and variable set
to the session name to be started duplicated. This gunks up the
stopping logic and leads to infinite recursion.
This commit cancels the start session operation to correct the bug.
https://bugzilla.gnome.org/show_bug.cgi?id=689367
-rw-r--r-- | daemon/gdm-simple-slave.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/daemon/gdm-simple-slave.c b/daemon/gdm-simple-slave.c index 8f5f0c6d..59b0627f 100644 --- a/daemon/gdm-simple-slave.c +++ b/daemon/gdm-simple-slave.c @@ -1567,6 +1567,14 @@ gdm_simple_slave_stop (GdmSlave *slave) self->priv->greeter_environment = NULL; } + if (self->priv->start_session_id > 0) { + g_source_remove (self->priv->start_session_id); + self->priv->start_session_id = 0; + } + + g_clear_pointer (&self->priv->start_session_service_name, + (GDestroyNotify) g_free); + if (self->priv->session_is_running) { char *username; |