mirror of
https://github.com/samba-team/samba.git
synced 2025-02-03 13:47:25 +03:00
s3: Remove talloc_autofree_context() from messaging_tdb_parent_init()
This commit is contained in:
parent
c4efae77fa
commit
8c55a9b459
@ -111,7 +111,7 @@ NTSTATUS messaging_tdb_init(struct messaging_context *msg_ctx,
|
||||
TALLOC_CTX *mem_ctx,
|
||||
struct messaging_backend **presult);
|
||||
|
||||
bool messaging_tdb_parent_init(void);
|
||||
bool messaging_tdb_parent_init(TALLOC_CTX *mem_ctx);
|
||||
|
||||
NTSTATUS messaging_ctdbd_init(struct messaging_context *msg_ctx,
|
||||
TALLOC_CTX *mem_ctx,
|
||||
|
@ -133,7 +133,7 @@ NTSTATUS messaging_tdb_init(struct messaging_context *msg_ctx,
|
||||
return NT_STATUS_OK;
|
||||
}
|
||||
|
||||
bool messaging_tdb_parent_init(void)
|
||||
bool messaging_tdb_parent_init(TALLOC_CTX *mem_ctx)
|
||||
{
|
||||
struct tdb_wrap *db;
|
||||
|
||||
@ -143,8 +143,7 @@ bool messaging_tdb_parent_init(void)
|
||||
* work.
|
||||
*/
|
||||
|
||||
db = tdb_wrap_open(talloc_autofree_context(),
|
||||
lock_path("messages.tdb"), 0,
|
||||
db = tdb_wrap_open(mem_ctx, lock_path("messages.tdb"), 0,
|
||||
TDB_CLEAR_IF_FIRST|TDB_DEFAULT|TDB_VOLATILE,
|
||||
O_RDWR|O_CREAT,0600);
|
||||
if (db == NULL) {
|
||||
|
@ -1126,7 +1126,7 @@ extern void build_options(bool screen);
|
||||
if (!locking_init())
|
||||
exit(1);
|
||||
|
||||
if (!messaging_tdb_parent_init()) {
|
||||
if (!messaging_tdb_parent_init(smbd_event_context())) {
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user