summaryrefslogtreecommitdiff
path: root/source3/passdb
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2005-08-23 13:58:05 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:01:11 -0500
commit1d1d2418f023d089d68dd26b0a43790f1307bd7c (patch)
tree8c7e99e68ba48c537219ab86a86d73e8ab0638b2 /source3/passdb
parent030bba20f1270eabb52eba5f95d85cc25f82e224 (diff)
downloadsamba-1d1d2418f023d089d68dd26b0a43790f1307bd7c.tar.gz
samba-1d1d2418f023d089d68dd26b0a43790f1307bd7c.tar.bz2
samba-1d1d2418f023d089d68dd26b0a43790f1307bd7c.zip
r9522: Give better error-message when "NDS Universal Password" change fails.
Guenther (This used to be commit df90ea016a1e5b48ad5731f9bee3764cf5478bc8)
Diffstat (limited to 'source3/passdb')
-rw-r--r--source3/passdb/pdb_nds.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source3/passdb/pdb_nds.c b/source3/passdb/pdb_nds.c
index 0b1d39a81b..3e5f8d1b93 100644
--- a/source3/passdb/pdb_nds.c
+++ b/source3/passdb/pdb_nds.c
@@ -714,9 +714,13 @@ int pdb_nds_set_password(
if (rc == LDAP_SUCCESS) {
DEBUG(5,("NDS Universal Password changed for user %s\n", object_dn));
} else {
+ char *ld_error = NULL;
+ ldap_get_option(ld, LDAP_OPT_ERROR_STRING, &ld_error);
+
/* This will fail if Universal Password is not enabled for the user's context */
- DEBUG(3,("NDS Universal Password could not be changed for user %s: %d\n",
- object_dn, rc));
+ DEBUG(3,("NDS Universal Password could not be changed for user %s: %s (%s)\n",
+ object_dn, ldap_err2string(rc), ld_error?ld_error:"unknown"));
+ SAFE_FREE(ld_error);
}
/* Set eDirectory Password */