diff options
author | Andrew Tridgell <tridge@samba.org> | 2009-10-25 17:19:03 +1100 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2009-10-25 17:19:03 +1100 |
commit | 54bd30f70632b8fcbe164133d2479092b7262a29 (patch) | |
tree | 588c4019f409b8234a15a53959d908cc9695e606 /source4/smb_server | |
parent | b55a5adab99f535bb392662d54afbabed116a3b6 (diff) | |
download | samba-54bd30f70632b8fcbe164133d2479092b7262a29.tar.gz samba-54bd30f70632b8fcbe164133d2479092b7262a29.tar.bz2 samba-54bd30f70632b8fcbe164133d2479092b7262a29.zip |
s4-samdb: reduce the number of samdb opens at startup
Using common parameters means that the ldb_wrap code can return a
reference rather than a new database
Diffstat (limited to 'source4/smb_server')
-rw-r--r-- | source4/smb_server/smb_server.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/source4/smb_server/smb_server.c b/source4/smb_server/smb_server.c index 9b10f66b2c..b0a37adba0 100644 --- a/source4/smb_server/smb_server.c +++ b/source4/smb_server/smb_server.c @@ -200,18 +200,6 @@ _PUBLIC_ NTSTATUS smbsrv_add_socket(struct tevent_context *event_context, /* - pre-open some of our ldb databases, to prevent an explosion of memory usage - when we fork - */ -static void smbsrv_preopen_ldb(struct task_server *task) -{ - /* yes, this looks strange. It is a hack to preload the - schema. I'd like to share most of the ldb context with the - child too. That will come later */ - talloc_free(samdb_connect(task, task->event_ctx, task->lp_ctx, NULL)); -} - -/* open the smb server sockets */ static void smbsrv_task_init(struct task_server *task) @@ -245,8 +233,6 @@ static void smbsrv_task_init(struct task_server *task) if (!NT_STATUS_IS_OK(status)) goto failed; } - smbsrv_preopen_ldb(task); - return; failed: task_server_terminate(task, "Failed to startup smb server task", true); |