summaryrefslogtreecommitdiff
path: root/source4/heimdal/lib/krb5/changepw.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2005-12-15 20:38:24 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:47:26 -0500
commitfbf106f6701c580f5839da575996de34fc953e1f (patch)
tree3691623409aab4ff0ede4b50cc4fcbfa255814f3 /source4/heimdal/lib/krb5/changepw.c
parentd8966dcd7e88df9817c81434056628c0beff21e3 (diff)
downloadsamba-fbf106f6701c580f5839da575996de34fc953e1f.tar.gz
samba-fbf106f6701c580f5839da575996de34fc953e1f.tar.bz2
samba-fbf106f6701c580f5839da575996de34fc953e1f.zip
r12269: Update to current lorikeet-heimdal. This changed the way the hdb
interface worked, so hdb-ldb.c and the glue have been updated. Andrew Bartlett (This used to be commit 8fd5224c6b5c17c3a2c04c7366b7e367012db77e)
Diffstat (limited to 'source4/heimdal/lib/krb5/changepw.c')
-rw-r--r--source4/heimdal/lib/krb5/changepw.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/source4/heimdal/lib/krb5/changepw.c b/source4/heimdal/lib/krb5/changepw.c
index c3cd6d4db9..7907e1ad9c 100644
--- a/source4/heimdal/lib/krb5/changepw.c
+++ b/source4/heimdal/lib/krb5/changepw.c
@@ -33,7 +33,7 @@
#include <krb5_locl.h>
-RCSID("$Id: changepw.c,v 1.54 2005/09/08 11:38:01 lha Exp $");
+RCSID("$Id: changepw.c,v 1.55 2005/12/12 12:48:57 lha Exp $");
static void
str2data (krb5_data *d,
@@ -522,7 +522,12 @@ change_password_loop (krb5_context context,
int sock;
int i;
int done = 0;
- krb5_realm realm = creds->client->realm;
+ krb5_realm realm;
+
+ if (targprinc)
+ realm = targprinc->realm;
+ else
+ realm = creds->client->realm;
ret = krb5_auth_con_init (context, &auth_context);
if (ret)
@@ -712,7 +717,7 @@ krb5_set_password(krb5_context context,
for (i = 0; procs[i].name != NULL; i++) {
*result_code = 0;
- ret = change_password_loop(context, creds, targprinc, newpw,
+ ret = change_password_loop(context, creds, principal, newpw,
result_code, result_code_string,
result_string,
&procs[i]);