summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2003-04-28 11:14:12 +0000
committerAndrew Bartlett <abartlet@samba.org>2003-04-28 11:14:12 +0000
commit9449d80f875cddd12626a0d40619989e6d6f7fa7 (patch)
tree457849e6ae65a232bb8f00a68958779dc780af32 /source3
parent49530d0db5a509951c66b73aaf2aa101caf6117b (diff)
downloadsamba-9449d80f875cddd12626a0d40619989e6d6f7fa7.tar.gz
samba-9449d80f875cddd12626a0d40619989e6d6f7fa7.tar.bz2
samba-9449d80f875cddd12626a0d40619989e6d6f7fa7.zip
Guenther Deschner <gd@suse.de> notes that I missed out setting the default
for the 'normal' case (not --with-ldapsam). Andrew Bartlett (This used to be commit ebe5c618189391e6adf27e565a5821f8d47c8c7d)
Diffstat (limited to 'source3')
-rw-r--r--source3/passdb/pdb_ldap.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c
index f9cd5345c7..607c77d30f 100644
--- a/source3/passdb/pdb_ldap.c
+++ b/source3/passdb/pdb_ldap.c
@@ -3176,10 +3176,12 @@ static NTSTATUS pdb_init_ldapsam_compat(PDB_CONTEXT *pdb_context, PDB_METHODS **
ldap_state = (*pdb_method)->private_data;
ldap_state->use_ntsid = False;
-#ifdef WITH_LDAP_SAMCONFIG
if (location) {
ldap_state->uri = talloc_strdup(pdb_context->mem_ctx, location);
} else {
+#ifndef WITH_LDAP_SAMCONFIG
+ ldap_state->uri = "ldap://localhost";
+#else
int ldap_port = lp_ldap_port();
/* remap default port if not using SSL (ie clear or TLS) */