summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2006-01-04 13:04:43 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:06:01 -0500
commitc3a2101da021abf52d06842598325a6cef6bbc83 (patch)
tree257f060b0a557f01bab4992073476f94353afbf1
parent2b509f470d616c8df69e72ec04e25114d22af50f (diff)
downloadsamba-c3a2101da021abf52d06842598325a6cef6bbc83.tar.gz
samba-c3a2101da021abf52d06842598325a6cef6bbc83.tar.bz2
samba-c3a2101da021abf52d06842598325a6cef6bbc83.zip
r12714: Fix segfault in pdb_nds.c.
Guenther (This used to be commit f78c7f8abea4cb598eca78fa3beacee8a3caee20)
-rw-r--r--source3/lib/smbldap.c8
-rw-r--r--source3/passdb/pdb_nds.c2
2 files changed, 5 insertions, 5 deletions
diff --git a/source3/lib/smbldap.c b/source3/lib/smbldap.c
index a3ebe72df2..609816b877 100644
--- a/source3/lib/smbldap.c
+++ b/source3/lib/smbldap.c
@@ -664,21 +664,21 @@ int smb_ldap_upgrade_conn(LDAP *ldap_struct, int *new_version)
open a connection to the ldap server (just until the bind)
******************************************************************/
-int smb_ldap_setup_full_conn(LDAP *ldap_struct, const char *uri)
+int smb_ldap_setup_full_conn(LDAP **ldap_struct, const char *uri)
{
int rc, version;
- rc = smb_ldap_setup_conn(&ldap_struct, uri);
+ rc = smb_ldap_setup_conn(ldap_struct, uri);
if (rc) {
return rc;
}
- rc = smb_ldap_upgrade_conn(ldap_struct, &version);
+ rc = smb_ldap_upgrade_conn(*ldap_struct, &version);
if (rc) {
return rc;
}
- rc = smb_ldap_start_tls(ldap_struct, version);
+ rc = smb_ldap_start_tls(*ldap_struct, version);
if (rc) {
return rc;
}
diff --git a/source3/passdb/pdb_nds.c b/source3/passdb/pdb_nds.c
index 1ec9693223..cf2d1d7c8a 100644
--- a/source3/passdb/pdb_nds.c
+++ b/source3/passdb/pdb_nds.c
@@ -807,7 +807,7 @@ static NTSTATUS pdb_nds_update_login_attempts(struct pdb_methods *methods,
if((success != True) || (got_clear_text_pw == True)) {
- rc = smb_ldap_setup_full_conn(ld, ldap_state->location);
+ rc = smb_ldap_setup_full_conn(&ld, ldap_state->location);
if (rc) {
return NT_STATUS_INVALID_CONNECTION;
}