From f13b7ec0791dc4f805a66300a540238aa57d3337 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 2 May 2011 10:06:56 +1000 Subject: s4-cluster: Remove const from cluster_id_string() This allows the caller to talloc_free() this result. Andrew Bartlett --- source4/cluster/cluster.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4/cluster/cluster.c') diff --git a/source4/cluster/cluster.c b/source4/cluster/cluster.c index 746c004820..315145afac 100644 --- a/source4/cluster/cluster.c +++ b/source4/cluster/cluster.c @@ -60,7 +60,7 @@ struct server_id cluster_id(uint64_t id, uint32_t id2) /* return a server_id as a string */ -const char *cluster_id_string(TALLOC_CTX *mem_ctx, struct server_id id) +char *cluster_id_string(TALLOC_CTX *mem_ctx, struct server_id id) { cluster_init(); return ops->cluster_id_string(ops, mem_ctx, id); -- cgit From cdd802af8319e0b0744d8e727cef75526269ece2 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Tue, 3 May 2011 10:40:33 +1000 Subject: s4-messaging Rename messaging -> imessaging This avoid symbol and structure conflicts between Samba3 and Samba4, and chooses a less generic name. Andrew Bartlett --- source4/cluster/cluster.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4/cluster/cluster.c') diff --git a/source4/cluster/cluster.c b/source4/cluster/cluster.c index 315145afac..441ea96562 100644 --- a/source4/cluster/cluster.c +++ b/source4/cluster/cluster.c @@ -80,7 +80,7 @@ struct tdb_wrap *cluster_tdb_tmp_open(TALLOC_CTX *mem_ctx, struct loadparm_conte /* register a callback function for a messaging endpoint */ -NTSTATUS cluster_message_init(struct messaging_context *msg, struct server_id server, +NTSTATUS cluster_message_init(struct imessaging_context *msg, struct server_id server, cluster_message_fn_t handler) { cluster_init(); -- cgit From 8d803d5a0a9a7815c4e6fcbd9b7c652fb85e94dd Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sun, 8 May 2011 18:28:17 +0200 Subject: s4-cluster Use task_id instead of id2 to clarify server_id structure This seems a clearer and more acceptable name. Andrew Bartlett Signed-off-by: Andrew Tridgell --- source4/cluster/cluster.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source4/cluster/cluster.c') diff --git a/source4/cluster/cluster.c b/source4/cluster/cluster.c index 441ea96562..9dcec2e3e0 100644 --- a/source4/cluster/cluster.c +++ b/source4/cluster/cluster.c @@ -50,10 +50,10 @@ static void cluster_init(void) /* create a server_id for the local node */ -struct server_id cluster_id(uint64_t id, uint32_t id2) +struct server_id cluster_id(uint64_t pid, uint32_t task_id) { cluster_init(); - return ops->cluster_id(ops, id, id2); + return ops->cluster_id(ops, pid, task_id); } -- cgit From d057116cc2e454ba097d0dcb22e16108a05a4a1b Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 2 May 2011 10:55:20 +1000 Subject: server_id.idl: Bring server_id.idl in common Andrew Bartlett Signed-off-by: Andrew Tridgell --- source4/cluster/cluster.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4/cluster/cluster.c') diff --git a/source4/cluster/cluster.c b/source4/cluster/cluster.c index 9dcec2e3e0..767e6a719f 100644 --- a/source4/cluster/cluster.c +++ b/source4/cluster/cluster.c @@ -23,7 +23,7 @@ #include "cluster/cluster.h" #include "cluster/cluster_private.h" #include "librpc/gen_ndr/misc.h" -#include "librpc/gen_ndr/server_id4.h" +#include "librpc/gen_ndr/server_id.h" static struct cluster_ops *ops; -- cgit From 16b1c77644217796f70a3a0bf1d95c245f9ee2d9 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Wed, 8 Jun 2011 14:05:55 +1000 Subject: lib/util Bring procid_str() into lib/util as server_id_string() This is needed for OpenChange, which prints Samba struct server_id values in debug messages. Andrew Bartlett --- source4/cluster/cluster.c | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'source4/cluster/cluster.c') diff --git a/source4/cluster/cluster.c b/source4/cluster/cluster.c index 767e6a719f..757489ebce 100644 --- a/source4/cluster/cluster.c +++ b/source4/cluster/cluster.c @@ -56,17 +56,6 @@ struct server_id cluster_id(uint64_t pid, uint32_t task_id) return ops->cluster_id(ops, pid, task_id); } - -/* - return a server_id as a string -*/ -char *cluster_id_string(TALLOC_CTX *mem_ctx, struct server_id id) -{ - cluster_init(); - return ops->cluster_id_string(ops, mem_ctx, id); -} - - /* open a temporary tdb in a cluster friendly manner */ -- cgit