[gdm/wip/shell-greeter: 20/23] greeter: "unified" extension fixes



commit ced14e0e114efdd310b2c05900dc642230c1cc3a
Author: Ray Strode <rstrode redhat com>
Date:   Tue Jul 12 10:16:18 2011 -0400

    greeter: "unified" extension fixes
    
    If gdm is built without --enable-split-authentication,
    then the "gdm" service gets used instead of the
    "gdm-password" service.
    
    The "Other" option (or when the user list is disabled)
    assumes "gdm-password" is right service to use.
    
    This commit fixes it to select "gdm" or "gdm-password" as
    appropriate.

 gui/simple-greeter/gdm-greeter-login-window.c |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/gui/simple-greeter/gdm-greeter-login-window.c b/gui/simple-greeter/gdm-greeter-login-window.c
index 2300ed5..ba8a0c5 100644
--- a/gui/simple-greeter/gdm-greeter-login-window.c
+++ b/gui/simple-greeter/gdm-greeter-login-window.c
@@ -752,10 +752,14 @@ static void
 begin_other_verification (GdmGreeterLoginWindow *login_window)
 {
         /* FIXME: we should drop this code and do all OTHER handling
-         * entirely from within the password plugin
+         * entirely from within the extension
          * (ala how smart card manages its "Smartcard Authentication" item)
          */
-        begin_single_service_verification (login_window, "gdm-password");
+        if (find_extension_with_service_name (login_window, "gdm-password") != NULL) {
+                begin_single_service_verification (login_window, "gdm-password");
+        } else {
+                begin_single_service_verification (login_window, "gdm");
+        }
 }
 
 static void
@@ -985,7 +989,8 @@ handle_stopped_conversation (GdmGreeterLoginWindow *login_window,
          *
          * FIXME: we need to get this policy out of the source code
          */
-        if (strcmp (service_name, "gdm-password") == 0) {
+        if (strcmp (service_name, "gdm-password") == 0 ||
+            strcmp (service_name, "gdm") == 0) {
                 g_debug ("GdmGreeterLoginWindow: main conversation failed, starting over");
                 restart_conversations (login_window);
                 reset_dialog_after_messages (login_window, MODE_SELECTION);



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