summaryrefslogtreecommitdiff
path: root/ctdb/server
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2015-10-29 16:42:05 +1100
committerMartin Schwenke <martins@samba.org>2015-11-04 00:47:14 +0100
commite1fed53e2abafcae8a5da9a3b24ee8db38b97441 (patch)
treeea38777c2f0e9eea4b3721a126ef5212e43a752d /ctdb/server
parentacf858defbe8672c91265e6e2afe45476ef0fba6 (diff)
downloadsamba-e1fed53e2abafcae8a5da9a3b24ee8db38b97441.tar.gz
ctdb-daemon: Rename struct ctdb_req_control to ctdb_req_control_old
Signed-off-by: Amitay Isaacs <amitay@gmail.com> Reviewed-by: Martin Schwenke <martin@meltin.net>
Diffstat (limited to 'ctdb/server')
-rw-r--r--ctdb/server/ctdb_control.c12
-rw-r--r--ctdb/server/ctdb_daemon.c8
-rw-r--r--ctdb/server/ctdb_freeze.c10
-rw-r--r--ctdb/server/ctdb_ltdb_server.c4
-rw-r--r--ctdb/server/ctdb_persistent.c8
-rw-r--r--ctdb/server/ctdb_recover.c10
-rw-r--r--ctdb/server/ctdb_statistics.c2
-rw-r--r--ctdb/server/ctdb_takeover.c34
-rw-r--r--ctdb/server/ctdb_update_record.c4
-rw-r--r--ctdb/server/eventscript.c4
10 files changed, 48 insertions, 48 deletions
diff --git a/ctdb/server/ctdb_control.c b/ctdb/server/ctdb_control.c
index 21ace77471d..99caba7995c 100644
--- a/ctdb/server/ctdb_control.c
+++ b/ctdb/server/ctdb_control.c
@@ -91,7 +91,7 @@ static int32_t control_not_implemented(const char *unsupported,
process a control request
*/
static int32_t ctdb_control_dispatch(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata,
TDB_DATA *outdata, uint32_t srcnode,
const char **errormsg,
@@ -724,7 +724,7 @@ static int32_t ctdb_control_dispatch(struct ctdb_context *ctdb,
/*
send a reply for a ctdb control
*/
-void ctdb_request_control_reply(struct ctdb_context *ctdb, struct ctdb_req_control *c,
+void ctdb_request_control_reply(struct ctdb_context *ctdb, struct ctdb_req_control_old *c,
TDB_DATA *outdata, int32_t status, const char *errormsg)
{
struct ctdb_reply_control *r;
@@ -767,7 +767,7 @@ void ctdb_request_control_reply(struct ctdb_context *ctdb, struct ctdb_req_contr
*/
void ctdb_request_control(struct ctdb_context *ctdb, struct ctdb_req_header *hdr)
{
- struct ctdb_req_control *c = (struct ctdb_req_control *)hdr;
+ struct ctdb_req_control_old *c = (struct ctdb_req_control_old *)hdr;
TDB_DATA data, *outdata;
int32_t status;
bool async_reply = false;
@@ -860,7 +860,7 @@ int ctdb_daemon_send_control(struct ctdb_context *ctdb, uint32_t destnode,
ctdb_control_callback_fn_t callback,
void *private_data)
{
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
struct ctdb_control_state *state;
size_t len;
@@ -901,9 +901,9 @@ int ctdb_daemon_send_control(struct ctdb_context *ctdb, uint32_t destnode,
talloc_set_destructor(state, ctdb_control_destructor);
- len = offsetof(struct ctdb_req_control, data) + data.dsize;
+ len = offsetof(struct ctdb_req_control_old, data) + data.dsize;
c = ctdb_transport_allocate(ctdb, state, CTDB_REQ_CONTROL, len,
- struct ctdb_req_control);
+ struct ctdb_req_control_old);
CTDB_NO_MEMORY(ctdb, c);
talloc_set_name_const(c, "ctdb_req_control packet");
diff --git a/ctdb/server/ctdb_daemon.c b/ctdb/server/ctdb_daemon.c
index f885a81f758..b95741c1479 100644
--- a/ctdb/server/ctdb_daemon.c
+++ b/ctdb/server/ctdb_daemon.c
@@ -811,7 +811,7 @@ static void daemon_request_call_from_client(struct ctdb_client *client,
static void daemon_request_control_from_client(struct ctdb_client *client,
- struct ctdb_req_control *c);
+ struct ctdb_req_control_old *c);
/* data contains a packet from the client */
static void daemon_incoming_packet(void *p, struct ctdb_req_header *hdr)
@@ -850,7 +850,7 @@ static void daemon_incoming_packet(void *p, struct ctdb_req_header *hdr)
case CTDB_REQ_CONTROL:
CTDB_INCREMENT_STAT(ctdb, client.req_control);
- daemon_request_control_from_client(client, (struct ctdb_req_control *)hdr);
+ daemon_request_control_from_client(client, (struct ctdb_req_control_old *)hdr);
break;
default:
@@ -1424,7 +1424,7 @@ struct ctdb_req_header *_ctdb_transport_allocate(struct ctdb_context *ctdb,
struct daemon_control_state {
struct daemon_control_state *next, *prev;
struct ctdb_client *client;
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
uint32_t reqid;
struct ctdb_node *node;
};
@@ -1498,7 +1498,7 @@ static int daemon_control_destructor(struct daemon_control_state *state)
from a local client over the unix domain socket
*/
static void daemon_request_control_from_client(struct ctdb_client *client,
- struct ctdb_req_control *c)
+ struct ctdb_req_control_old *c)
{
TDB_DATA data;
int res;
diff --git a/ctdb/server/ctdb_freeze.c b/ctdb/server/ctdb_freeze.c
index 83a088fea03..94c070077ea 100644
--- a/ctdb/server/ctdb_freeze.c
+++ b/ctdb/server/ctdb_freeze.c
@@ -215,8 +215,8 @@ static void ctdb_start_db_freeze(struct ctdb_db_context *ctdb_db)
static int ctdb_db_freeze_waiter_destructor(struct ctdb_db_freeze_waiter *w)
{
/* 'c' pointer is talloc_memdup(), so cannot use talloc_get_type */
- struct ctdb_req_control *c =
- (struct ctdb_req_control *)w->private_data;
+ struct ctdb_req_control_old *c =
+ (struct ctdb_req_control_old *)w->private_data;
ctdb_request_control_reply(w->ctdb, c, NULL, w->status, NULL);
return 0;
@@ -226,7 +226,7 @@ static int ctdb_db_freeze_waiter_destructor(struct ctdb_db_freeze_waiter *w)
* freeze a database
*/
int32_t ctdb_control_db_freeze(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
uint32_t db_id,
bool *async_reply)
{
@@ -288,7 +288,7 @@ int32_t ctdb_control_db_thaw(struct ctdb_context *ctdb, uint32_t db_id)
struct ctdb_freeze_waiter {
struct ctdb_freeze_waiter *next, *prev;
struct ctdb_context *ctdb;
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
uint32_t priority;
int32_t status;
};
@@ -546,7 +546,7 @@ static int ctdb_freeze_waiter_destructor(struct ctdb_freeze_waiter *w)
/*
freeze the databases
*/
-int32_t ctdb_control_freeze(struct ctdb_context *ctdb, struct ctdb_req_control *c, bool *async_reply)
+int32_t ctdb_control_freeze(struct ctdb_context *ctdb, struct ctdb_req_control_old *c, bool *async_reply)
{
struct ctdb_freeze_waiter *w;
uint32_t priority;
diff --git a/ctdb/server/ctdb_ltdb_server.c b/ctdb/server/ctdb_ltdb_server.c
index 54cf7a01857..43181dc2afe 100644
--- a/ctdb/server/ctdb_ltdb_server.c
+++ b/ctdb/server/ctdb_ltdb_server.c
@@ -1036,7 +1036,7 @@ again:
struct ctdb_deferred_attach_context {
struct ctdb_deferred_attach_context *next, *prev;
struct ctdb_context *ctdb;
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
};
@@ -1093,7 +1093,7 @@ int ctdb_process_deferred_attach(struct ctdb_context *ctdb)
int32_t ctdb_control_db_attach(struct ctdb_context *ctdb, TDB_DATA indata,
TDB_DATA *outdata, uint64_t tdb_flags,
bool persistent, uint32_t client_id,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
bool *async_reply)
{
const char *db_name = (const char *)indata.dptr;
diff --git a/ctdb/server/ctdb_persistent.c b/ctdb/server/ctdb_persistent.c
index e5ad2fa7f6d..10e68351042 100644
--- a/ctdb/server/ctdb_persistent.c
+++ b/ctdb/server/ctdb_persistent.c
@@ -41,7 +41,7 @@ struct ctdb_persistent_state {
struct ctdb_context *ctdb;
struct ctdb_db_context *ctdb_db; /* used by trans3_commit */
struct ctdb_client *client; /* used by trans3_commit */
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
const char *errormsg;
uint32_t num_pending;
int32_t status;
@@ -173,7 +173,7 @@ static int ctdb_persistent_state_destructor(struct ctdb_persistent_state *state)
* This is used to roll out a transaction to all nodes.
*/
int32_t ctdb_control_trans3_commit(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA recdata, bool *async_reply)
{
struct ctdb_client *client;
@@ -287,7 +287,7 @@ int32_t ctdb_control_trans3_commit(struct ctdb_context *ctdb,
for now we ignore the recdata that the client has passed to us.
*/
int32_t ctdb_control_start_persistent_update(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA recdata)
{
struct ctdb_client *client = reqid_find(ctdb->idr, c->client_id, struct ctdb_client);
@@ -308,7 +308,7 @@ int32_t ctdb_control_start_persistent_update(struct ctdb_context *ctdb,
called to tell ctdbd that it is no longer doing a persistent update
*/
int32_t ctdb_control_cancel_persistent_update(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA recdata)
{
struct ctdb_client *client = reqid_find(ctdb->idr, c->client_id, struct ctdb_client);
diff --git a/ctdb/server/ctdb_recover.c b/ctdb/server/ctdb_recover.c
index c898b95e1ab..9d5c7d7f02e 100644
--- a/ctdb/server/ctdb_recover.c
+++ b/ctdb/server/ctdb_recover.c
@@ -408,7 +408,7 @@ failed:
struct ctdb_set_recmode_state {
struct ctdb_context *ctdb;
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
uint32_t recmode;
int fd[2];
struct tevent_timer *te;
@@ -539,7 +539,7 @@ int ctdb_deferred_drop_all_ips(struct ctdb_context *ctdb)
set the recovery mode
*/
int32_t ctdb_control_set_recmode(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata, bool *async_reply,
const char **errormsg)
{
@@ -858,7 +858,7 @@ static int delete_tdb_record(struct ctdb_context *ctdb, struct ctdb_db_context *
struct recovery_callback_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
};
@@ -893,7 +893,7 @@ static void ctdb_end_recovery_callback(struct ctdb_context *ctdb, int status, vo
recovery has finished
*/
int32_t ctdb_control_end_recovery(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
bool *async_reply)
{
int ret;
@@ -948,7 +948,7 @@ static void ctdb_start_recovery_callback(struct ctdb_context *ctdb, int status,
run the startrecovery eventscript
*/
int32_t ctdb_control_start_recovery(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
bool *async_reply)
{
int ret;
diff --git a/ctdb/server/ctdb_statistics.c b/ctdb/server/ctdb_statistics.c
index c96858631b0..7987a318fac 100644
--- a/ctdb/server/ctdb_statistics.c
+++ b/ctdb/server/ctdb_statistics.c
@@ -67,7 +67,7 @@ int ctdb_statistics_init(struct ctdb_context *ctdb)
int32_t ctdb_control_get_stat_history(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA *outdata)
{
int len;
diff --git a/ctdb/server/ctdb_takeover.c b/ctdb/server/ctdb_takeover.c
index 61a3a8d5a2c..78e9e7852c8 100644
--- a/ctdb/server/ctdb_takeover.c
+++ b/ctdb/server/ctdb_takeover.c
@@ -404,13 +404,13 @@ static int32_t ctdb_announce_vnn_iface(struct ctdb_context *ctdb,
}
struct takeover_callback_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
ctdb_sock_addr *addr;
struct ctdb_vnn *vnn;
};
struct ctdb_do_takeip_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
struct ctdb_vnn *vnn;
};
@@ -475,7 +475,7 @@ static int ctdb_takeip_destructor(struct ctdb_do_takeip_state *state)
take over an ip address
*/
static int32_t ctdb_do_takeip(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
struct ctdb_vnn *vnn)
{
int ret;
@@ -534,7 +534,7 @@ static int32_t ctdb_do_takeip(struct ctdb_context *ctdb,
}
struct ctdb_do_updateip_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
struct ctdb_iface *old;
struct ctdb_vnn *vnn;
};
@@ -598,7 +598,7 @@ static int ctdb_updateip_destructor(struct ctdb_do_updateip_state *state)
update (move) an ip address
*/
static int32_t ctdb_do_updateip(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
struct ctdb_vnn *vnn)
{
int ret;
@@ -694,7 +694,7 @@ static struct ctdb_vnn *find_public_ip_vnn(struct ctdb_context *ctdb, ctdb_sock_
take over an ip address
*/
int32_t ctdb_control_takeover_ip(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata,
bool *async_reply)
{
@@ -926,7 +926,7 @@ static int ctdb_releaseip_destructor(struct takeover_callback_state *state)
release an ip address
*/
int32_t ctdb_control_release_ip(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata,
bool *async_reply)
{
@@ -3197,7 +3197,7 @@ void ctdb_release_all_ips(struct ctdb_context *ctdb)
get list of public IPs
*/
int32_t ctdb_control_get_public_ips(struct ctdb_context *ctdb,
- struct ctdb_req_control *c, TDB_DATA *outdata)
+ struct ctdb_req_control_old *c, TDB_DATA *outdata)
{
int i, num, len;
struct ctdb_all_public_ips *ips;
@@ -3240,7 +3240,7 @@ int32_t ctdb_control_get_public_ips(struct ctdb_context *ctdb,
int32_t ctdb_control_get_public_ip_info(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata,
TDB_DATA *outdata)
{
@@ -3309,7 +3309,7 @@ int32_t ctdb_control_get_public_ip_info(struct ctdb_context *ctdb,
}
int32_t ctdb_control_get_ifaces(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA *outdata)
{
int i, num, len;
@@ -3345,7 +3345,7 @@ int32_t ctdb_control_get_ifaces(struct ctdb_context *ctdb,
}
int32_t ctdb_control_set_iface_link(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata)
{
struct ctdb_control_iface_info *info;
@@ -4058,7 +4058,7 @@ int32_t ctdb_control_add_public_address(struct ctdb_context *ctdb, TDB_DATA inda
}
struct delete_ip_callback_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
};
/*
@@ -4078,7 +4078,7 @@ static void delete_ip_callback(struct ctdb_context *ctdb,
}
int32_t ctdb_control_del_public_address(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata, bool *async_reply)
{
struct ctdb_control_ip_iface *pub = (struct ctdb_control_ip_iface *)indata.dptr;
@@ -4167,7 +4167,7 @@ int32_t ctdb_control_del_public_address(struct ctdb_context *ctdb,
struct ipreallocated_callback_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
};
static void ctdb_ipreallocated_callback(struct ctdb_context *ctdb,
@@ -4191,7 +4191,7 @@ static void ctdb_ipreallocated_callback(struct ctdb_context *ctdb,
/* A control to run the ipreallocated event */
int32_t ctdb_control_ipreallocated(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
bool *async_reply)
{
int ret;
@@ -4299,7 +4299,7 @@ void clear_ip_assignment_tree(struct ctdb_context *ctdb)
struct ctdb_reloadips_handle {
struct ctdb_context *ctdb;
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
int status;
int fd[2];
pid_t child;
@@ -4525,7 +4525,7 @@ failed:
and drop any addresses we should nnot longer host, and add new addresses
that we are now able to host
*/
-int32_t ctdb_control_reload_public_ips(struct ctdb_context *ctdb, struct ctdb_req_control *c, bool *async_reply)
+int32_t ctdb_control_reload_public_ips(struct ctdb_context *ctdb, struct ctdb_req_control_old *c, bool *async_reply)
{
struct ctdb_reloadips_handle *h;
pid_t parent = getpid();
diff --git a/ctdb/server/ctdb_update_record.c b/ctdb/server/ctdb_update_record.c
index 17d4df5450e..64fda3fa688 100644
--- a/ctdb/server/ctdb_update_record.c
+++ b/ctdb/server/ctdb_update_record.c
@@ -39,7 +39,7 @@
struct ctdb_persistent_write_state {
struct ctdb_db_context *ctdb_db;
struct ctdb_marshall_buffer *m;
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
uint32_t flags;
};
@@ -309,7 +309,7 @@ static struct childwrite_handle *ctdb_childwrite(
current record
*/
int32_t ctdb_control_update_record(struct ctdb_context *ctdb,
- struct ctdb_req_control *c, TDB_DATA recdata,
+ struct ctdb_req_control_old *c, TDB_DATA recdata,
bool *async_reply)
{
struct ctdb_db_context *ctdb_db;
diff --git a/ctdb/server/eventscript.c b/ctdb/server/eventscript.c
index b847e5adf8c..41acd0754e2 100644
--- a/ctdb/server/eventscript.c
+++ b/ctdb/server/eventscript.c
@@ -928,7 +928,7 @@ int ctdb_event_script(struct ctdb_context *ctdb, enum ctdb_event call)
}
struct eventscript_callback_state {
- struct ctdb_req_control *c;
+ struct ctdb_req_control_old *c;
};
/*
@@ -985,7 +985,7 @@ static const char *get_call(const char *p, enum ctdb_event *call)
A control to force running of the eventscripts from the ctdb client tool
*/
int32_t ctdb_run_eventscripts(struct ctdb_context *ctdb,
- struct ctdb_req_control *c,
+ struct ctdb_req_control_old *c,
TDB_DATA indata, bool *async_reply)
{
int ret;