[gdm] daemon: stop sending back the saved session name after the user setup is done



commit ba5b6b1daf9f995cd0b56cebef602fe7b21b678e
Author: Gary Ching-Pang Lin <chingpang gmail com>
Date:   Fri Jun 3 16:33:42 2011 +0800

    daemon: stop sending back the saved session name after the user setup is done
    
    The greeter needs not to know the saved session after the user
    settings are loaded successfully. Sending back the saved session
    name could potentially form an infinite loop between the daemon
    and the greeter.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=569039

 daemon/gdm-session-worker.c |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/daemon/gdm-session-worker.c b/daemon/gdm-session-worker.c
index a7e2bd9..447e184 100644
--- a/daemon/gdm-session-worker.c
+++ b/daemon/gdm-session-worker.c
@@ -2018,6 +2018,18 @@ do_setup (GdmSessionWorker *worker)
                 return;
         }
 
+        /* These singal handlers should be disconnected after the loading,
+         * so that gdm_session_settings_set_* APIs don't cause the emitting
+         * of Saved*NameRead D-Bus signals any more.
+         */
+        g_signal_handlers_disconnect_by_func (worker->priv->user_settings,
+                                              G_CALLBACK (on_saved_session_name_read),
+                                              worker);
+
+        g_signal_handlers_disconnect_by_func (worker->priv->user_settings,
+                                              G_CALLBACK (on_saved_language_name_read),
+                                              worker);
+
         send_dbus_void_method (worker->priv->connection, "SetupComplete");
 }
 



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