diff options
author | Stefan Metzmacher <metze@samba.org> | 2009-01-14 12:25:31 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2009-01-20 00:41:45 +0100 |
commit | 930b3c15da0bb24672d95ed388957b542cb24f89 (patch) | |
tree | 95b75b411c3d1cd4c45f3ab79b7a58ba9a00ff3e /source3 | |
parent | 26e863e6dd864d6466165adebce716f79bec73b6 (diff) | |
download | samba-930b3c15da0bb24672d95ed388957b542cb24f89.tar.gz samba-930b3c15da0bb24672d95ed388957b542cb24f89.tar.bz2 samba-930b3c15da0bb24672d95ed388957b542cb24f89.zip |
s3:messaging: also recreate the local messaging backend in messaging_reinit()
This prepares the change to use signal events in the tdb backend.
metze
Diffstat (limited to 'source3')
-rw-r--r-- | source3/lib/messages.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/source3/lib/messages.c b/source3/lib/messages.c index f5933cafdb..e4b20c7493 100644 --- a/source3/lib/messages.c +++ b/source3/lib/messages.c @@ -235,13 +235,21 @@ struct messaging_context *messaging_init(TALLOC_CTX *mem_ctx, */ NTSTATUS messaging_reinit(struct messaging_context *msg_ctx) { -#ifdef CLUSTER_SUPPORT + NTSTATUS status; + + TALLOC_FREE(msg_ctx->local); + + status = messaging_tdb_init(msg_ctx, msg_ctx, &msg_ctx->local); + if (!NT_STATUS_IS_OK(status)) { + DEBUG(0, ("messaging_tdb_init failed: %s\n", + nt_errstr(status))); + return status; + } +#ifdef CLUSTER_SUPPORT TALLOC_FREE(msg_ctx->remote); if (lp_clustering()) { - NTSTATUS status; - status = messaging_ctdbd_init(msg_ctx, msg_ctx, &msg_ctx->remote); |