aboutsummaryrefslogtreecommitdiff
path: root/debian/patches/Use-current-user-name-to-determine-principal.patch
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2014-10-20 13:58:09 +0200
committerGuido Günther <agx@sigxcpu.org>2014-10-20 13:58:09 +0200
commita9cf1c18633c78b8deb5616996f3c2c5b72e499a (patch)
tree8146b4c1fbe2a07a906d8508b5ebb69d9e7c45ad /debian/patches/Use-current-user-name-to-determine-principal.patch
parentDocument changes and release 3.12.0-1 (diff)
downloadkrb5-auth-dialog-a9cf1c18633c78b8deb5616996f3c2c5b72e499a.tar.gz
krb5-auth-dialog-a9cf1c18633c78b8deb5616996f3c2c5b72e499a.tar.bz2
krb5-auth-dialog-a9cf1c18633c78b8deb5616996f3c2c5b72e499a.zip
Use current user name to determine principal
Closes: #762906
Diffstat (limited to 'debian/patches/Use-current-user-name-to-determine-principal.patch')
-rw-r--r--debian/patches/Use-current-user-name-to-determine-principal.patch26
1 files changed, 26 insertions, 0 deletions
diff --git a/debian/patches/Use-current-user-name-to-determine-principal.patch b/debian/patches/Use-current-user-name-to-determine-principal.patch
new file mode 100644
index 0000000..77b9ebb
--- /dev/null
+++ b/debian/patches/Use-current-user-name-to-determine-principal.patch
@@ -0,0 +1,26 @@
+From: =?utf-8?q?Guido_G=C3=BCnther?= <agx@sigxcpu.org>
+Date: Mon, 20 Oct 2014 10:31:16 +0200
+Subject: Use current user name to determine principal
+
+This got broken when switching from GConf to GSettings.
+
+Closes: #762906
+---
+ src/ka-kerberos.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/ka-kerberos.c b/src/ka-kerberos.c
+index 2b0106e..d3559b6 100644
+--- a/src/ka-kerberos.c
++++ b/src/ka-kerberos.c
+@@ -649,6 +649,10 @@ ka_parse_name (KaApplet *applet, krb5_context krbcontext,
+ krb5_free_principal (krbcontext, *kprinc);
+
+ g_object_get (applet, KA_PROP_NAME_PRINCIPAL, &principal, NULL);
++ if (principal[0] == '\0') {
++ g_free (principal);
++ principal = g_strdup (g_get_user_name());
++ }
+ ret = krb5_parse_name (krbcontext, principal, kprinc);
+
+ g_free (principal);
bgstack15