git.samba.org
/
ira
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1d3bdf3
)
Don't keep an extra ldb around forever.
author
Andrew Bartlett
<abartlet@samba.org>
Wed, 16 Jul 2008 01:11:25 +0000
(11:11 +1000)
committer
Andrew Bartlett
<abartlet@samba.org>
Wed, 16 Jul 2008 01:11:25 +0000
(11:11 +1000)
We just open it to figure out if we need to be a Global Catalog server.
Andrew Bartlett
(This used to be commit
f13572d9e9f1962b637cbd573588184d1459d252
)
source4/ldap_server/ldap_server.c
patch
|
blob
|
history
diff --git
a/source4/ldap_server/ldap_server.c
b/source4/ldap_server/ldap_server.c
index 197f84692c14bb82cdce6cdba01acc61b3dc7110..39a55f4420d1b1bf6579026f2ca663494e212f75 100644
(file)
--- a/
source4/ldap_server/ldap_server.c
+++ b/
source4/ldap_server/ldap_server.c
@@
-477,7
+477,7
@@
static NTSTATUS add_socket(struct event_context *event_context,
}
}
- /* Load LDAP database */
+ /* Load LDAP database
, but only to read our settings
*/
ldb = samdb_connect(ldap_service, ldap_service->task->event_ctx,
lp_ctx, system_session(ldap_service, lp_ctx));
if (!ldb) {
@@
-497,6
+497,10
@@
static NTSTATUS add_socket(struct event_context *event_context,
}
}
+ /* And once we are bound, free the tempoary ldb, it will
+ * connect again on each incoming LDAP connection */
+ talloc_free(ldb);
+
return status;
}