summaryrefslogtreecommitdiff
path: root/ctdb
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2018-02-15 12:21:57 +1100
committerKarolin Seeger <kseeger@samba.org>2018-10-09 11:29:25 +0200
commitb8040119285a50edf1596b4dce64a5f97e2f54e7 (patch)
treee7106f4a403f74809722b3af34b050c8b879d6d4 /ctdb
parent3c32e6b9b9cf4cafe2b513e07ecada11e1bdf09a (diff)
downloadsamba-b8040119285a50edf1596b4dce64a5f97e2f54e7.tar.gz
ctdb-protocol: Drop marshalling code for RECEIVE_RECORDS control
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13641 Signed-off-by: Amitay Isaacs <amitay@gmail.com> Reviewed-by: Martin Schwenke <martin@meltin.net> (cherry picked from commit 2f89bd96fb6c5e50cfc09604ceb6b96a94cb4f56)
Diffstat (limited to 'ctdb')
-rw-r--r--ctdb/protocol/protocol_api.h6
-rw-r--r--ctdb/protocol/protocol_client.c29
-rw-r--r--ctdb/protocol/protocol_control.c26
3 files changed, 0 insertions, 61 deletions
diff --git a/ctdb/protocol/protocol_api.h b/ctdb/protocol/protocol_api.h
index 8b40d1d8c0e..04a229c3ab4 100644
--- a/ctdb/protocol/protocol_api.h
+++ b/ctdb/protocol/protocol_api.h
@@ -530,12 +530,6 @@ int ctdb_reply_control_set_db_sticky(struct ctdb_reply_control *reply);
void ctdb_req_control_reload_public_ips(struct ctdb_req_control *request);
int ctdb_reply_control_reload_public_ips(struct ctdb_reply_control *reply);
-void ctdb_req_control_receive_records(struct ctdb_req_control *request,
- struct ctdb_rec_buffer *recbuf);
-int ctdb_reply_control_receive_records(struct ctdb_reply_control *reply,
- TALLOC_CTX *mem_ctx,
- struct ctdb_rec_buffer **recbuf);
-
void ctdb_req_control_ipreallocated(struct ctdb_req_control *request);
int ctdb_reply_control_ipreallocated(struct ctdb_reply_control *reply);
diff --git a/ctdb/protocol/protocol_client.c b/ctdb/protocol/protocol_client.c
index a18af08e21a..9aa32a9bba7 100644
--- a/ctdb/protocol/protocol_client.c
+++ b/ctdb/protocol/protocol_client.c
@@ -1948,35 +1948,6 @@ int ctdb_reply_control_reload_public_ips(struct ctdb_reply_control *reply)
/* CTDB_CONTROL_TRAVERSE_ALL_EXT */
-/* CTDB_CONTROL_RECEIVE_RECORDS */
-
-void ctdb_req_control_receive_records(struct ctdb_req_control *request,
- struct ctdb_rec_buffer *recbuf)
-{
- request->opcode = CTDB_CONTROL_RECEIVE_RECORDS;
- request->pad = 0;
- request->srvid = 0;
- request->client_id = 0;
- request->flags = 0;
-
- request->rdata.opcode = CTDB_CONTROL_RECEIVE_RECORDS;
- request->rdata.data.recbuf = recbuf;
-}
-
-int ctdb_reply_control_receive_records(struct ctdb_reply_control *reply,
- TALLOC_CTX *mem_ctx,
- struct ctdb_rec_buffer **recbuf)
-{
- if (reply->rdata.opcode != CTDB_CONTROL_RECEIVE_RECORDS) {
- return EPROTO;
- }
-
- if (reply->status == 0) {
- *recbuf = talloc_steal(mem_ctx, reply->rdata.data.recbuf);
- }
- return reply->status;
-}
-
/* CTDB_CONTROL_IPREALLOCATED */
void ctdb_req_control_ipreallocated(struct ctdb_req_control *request)
diff --git a/ctdb/protocol/protocol_control.c b/ctdb/protocol/protocol_control.c
index 12a78e1792d..0b88b5c8b5a 100644
--- a/ctdb/protocol/protocol_control.c
+++ b/ctdb/protocol/protocol_control.c
@@ -360,10 +360,6 @@ static size_t ctdb_req_control_data_len(struct ctdb_req_control_data *cd)
len = ctdb_traverse_all_ext_len(cd->data.traverse_all_ext);
break;
- case CTDB_CONTROL_RECEIVE_RECORDS:
- len = ctdb_rec_buffer_len(cd->data.recbuf);
- break;
-
case CTDB_CONTROL_IPREALLOCATED:
break;
@@ -660,10 +656,6 @@ static void ctdb_req_control_data_push(struct ctdb_req_control_data *cd,
&np);
break;
- case CTDB_CONTROL_RECEIVE_RECORDS:
- ctdb_rec_buffer_push(cd->data.recbuf, buf, &np);
- break;
-
case CTDB_CONTROL_DB_DETACH:
ctdb_uint32_push(&cd->data.db_id, buf, &np);
break;
@@ -988,11 +980,6 @@ static int ctdb_req_control_data_pull(uint8_t *buf, size_t buflen,
&np);
break;
- case CTDB_CONTROL_RECEIVE_RECORDS:
- ret = ctdb_rec_buffer_pull(buf, buflen, mem_ctx,
- &cd->data.recbuf, &np);
- break;
-
case CTDB_CONTROL_DB_DETACH:
ret = ctdb_uint32_pull(buf, buflen, &cd->data.db_id, &np);
break;
@@ -1368,10 +1355,6 @@ static size_t ctdb_reply_control_data_len(struct ctdb_reply_control_data *cd)
case CTDB_CONTROL_TRAVERSE_ALL_EXT:
break;
- case CTDB_CONTROL_RECEIVE_RECORDS:
- len = ctdb_rec_buffer_len(cd->data.recbuf);
- break;
-
case CTDB_CONTROL_IPREALLOCATED:
break;
@@ -1562,10 +1545,6 @@ static void ctdb_reply_control_data_push(struct ctdb_reply_control_data *cd,
ctdb_db_statistics_push(cd->data.dbstats, buf, &np);
break;
- case CTDB_CONTROL_RECEIVE_RECORDS:
- ctdb_rec_buffer_push(cd->data.recbuf, buf, &np);
- break;
-
case CTDB_CONTROL_GET_RUNSTATE:
ctdb_uint32_push(&cd->data.runstate, buf, &np);
break;
@@ -1753,11 +1732,6 @@ static int ctdb_reply_control_data_pull(uint8_t *buf, size_t buflen,
&cd->data.dbstats, &np);
break;
- case CTDB_CONTROL_RECEIVE_RECORDS:
- ret = ctdb_rec_buffer_pull(buf, buflen, mem_ctx,
- &cd->data.recbuf, &np);
- break;
-
case CTDB_CONTROL_GET_RUNSTATE:
ret = ctdb_uint32_pull(buf, buflen, &cd->data.runstate, &np);
break;