summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2012-04-04 11:27:08 +0200
committerVolker Lendecke <vl@samba.org>2012-04-17 10:21:02 +0200
commita03a74c35388ed23681a2381252a85bef7cafbe7 (patch)
treecd6fa90b898eb084794c8a567eb5378c2c90b6a4
parentb23b35755750589b201a3f4e85521459f575945c (diff)
downloadsamba-a03a74c35388ed23681a2381252a85bef7cafbe7.tar.gz
samba-a03a74c35388ed23681a2381252a85bef7cafbe7.tar.bz2
samba-a03a74c35388ed23681a2381252a85bef7cafbe7.zip
s3: Make messaging_ctdbd_connection available in non-clustered mode
This might make some #ifdef CLUSTER_SUPPORT unnecessary in the future
-rw-r--r--source3/lib/messages_ctdbd.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/source3/lib/messages_ctdbd.c b/source3/lib/messages_ctdbd.c
index b7db2a76f0..7899477ba0 100644
--- a/source3/lib/messages_ctdbd.c
+++ b/source3/lib/messages_ctdbd.c
@@ -59,6 +59,10 @@ static int global_ctdb_connection_pid;
struct ctdbd_connection *messaging_ctdbd_connection(void)
{
+ if (!lp_clustering()) {
+ return NULL;
+ }
+
if (global_ctdb_connection_pid == 0 &&
global_ctdbd_connection == NULL) {
struct event_context *ev;
@@ -174,4 +178,9 @@ NTSTATUS messaging_ctdbd_init(struct messaging_context *msg_ctx,
return NT_STATUS_NOT_IMPLEMENTED;
}
+struct ctdbd_connection *messaging_ctdbd_connection(void)
+{
+ return NULL;
+}
+
#endif