[krb5-auth-dialog] Improve error message when without network connection



commit 4cb70e0f0dcf2c2979c0b3af49a1160a28611a95
Author: Guido Günther <agx sigxcpu org>
Date:   Tue Jun 10 14:01:26 2014 +0200

    Improve error message when without network connection
    
    Kerberos Error messages can be confusing without network connection,
    e.g. current heimdal reports EINVAL. So report if we're online as
    additional information.

 src/ka-kerberos.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/ka-kerberos.c b/src/ka-kerberos.c
index f57c547..a6ec530 100644
--- a/src/ka-kerberos.c
+++ b/src/ka-kerberos.c
@@ -1027,7 +1027,9 @@ ka_grab_credentials (KaApplet *applet)
         if (retval) {
             gchar *errmsg;
 
-            errmsg = ka_get_error_message (kcontext, retval);
+            errmsg = g_strdup_printf("%s%s",
+                                     ka_get_error_message (kcontext, retval),
+                                     is_online ? "" : _(" (No network connection)"));
             ka_pwdialog_error (pwdialog, errmsg);
             g_free (errmsg);
             break;


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