mirror of
https://github.com/samba-team/samba.git
synced 2025-01-10 01:18:15 +03:00
ctdb-protocol: Drop marshalling functions for old-style database pull/push
Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
This commit is contained in:
parent
3bbb4a8535
commit
7d826731d4
@ -68,14 +68,6 @@ static size_t ctdb_req_control_data_len(struct ctdb_req_control_data *cd)
|
||||
case CTDB_CONTROL_GET_DBMAP:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
len = ctdb_pulldb_len(cd->data.pulldb);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
len = ctdb_rec_buffer_len(cd->data.recbuf);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_GET_RECMODE:
|
||||
break;
|
||||
|
||||
@ -447,14 +439,6 @@ static void ctdb_req_control_data_push(struct ctdb_req_control_data *cd,
|
||||
ctdb_uint32_push(&cd->data.loglevel, buf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
ctdb_pulldb_push(cd->data.pulldb, buf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
ctdb_rec_buffer_push(cd->data.recbuf, buf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_SET_RECMODE:
|
||||
ctdb_uint32_push(&cd->data.recmode, buf, &np);
|
||||
break;
|
||||
@ -741,16 +725,6 @@ static int ctdb_req_control_data_pull(uint8_t *buf, size_t buflen,
|
||||
ret = ctdb_uint32_pull(buf, buflen, &cd->data.loglevel, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
ret = ctdb_pulldb_pull(buf, buflen, mem_ctx,
|
||||
&cd->data.pulldb, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
ret = ctdb_rec_buffer_pull(buf, buflen, mem_ctx,
|
||||
&cd->data.recbuf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_SET_RECMODE:
|
||||
ret = ctdb_uint32_pull(buf, buflen, &cd->data.recmode, &np);
|
||||
break;
|
||||
@ -1102,13 +1076,6 @@ static size_t ctdb_reply_control_data_len(struct ctdb_reply_control_data *cd)
|
||||
len = ctdb_dbid_map_len(cd->data.dbmap);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
len = ctdb_rec_buffer_len(cd->data.recbuf);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_GET_RECMODE:
|
||||
break;
|
||||
|
||||
@ -1449,13 +1416,6 @@ static void ctdb_reply_control_data_push(struct ctdb_reply_control_data *cd,
|
||||
ctdb_dbid_map_push(cd->data.dbmap, buf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
ctdb_rec_buffer_push(cd->data.recbuf, buf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_DB_ATTACH:
|
||||
ctdb_uint32_push(&cd->data.db_id, buf, &np);
|
||||
break;
|
||||
@ -1622,14 +1582,6 @@ static int ctdb_reply_control_data_pull(uint8_t *buf, size_t buflen,
|
||||
&cd->data.dbmap, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
ret = ctdb_rec_buffer_pull(buf, buflen, mem_ctx,
|
||||
&cd->data.recbuf, &np);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_DB_ATTACH:
|
||||
ret = ctdb_uint32_pull(buf, buflen, &cd->data.db_id, &np);
|
||||
break;
|
||||
|
@ -114,8 +114,6 @@ static void ctdb_opcode_print(uint32_t opcode, FILE *fp)
|
||||
{ CTDB_CONTROL_GET_DBMAP, "GET_DBMAP" },
|
||||
{ CTDB_CONTROL_GET_NODEMAPv4, "GET_NODEMAPv4" },
|
||||
{ CTDB_CONTROL_SET_DMASTER, "SET_DMASTER" },
|
||||
{ CTDB_CONTROL_PULL_DB, "PULL_DB" },
|
||||
{ CTDB_CONTROL_PUSH_DB, "PUSH_DB" },
|
||||
{ CTDB_CONTROL_GET_RECMODE, "GET_RECMODE" },
|
||||
{ CTDB_CONTROL_SET_RECMODE, "SET_RECMODE" },
|
||||
{ CTDB_CONTROL_STATISTICS_RESET, "STATISTICS_RESET" },
|
||||
|
@ -176,18 +176,6 @@ void fill_ctdb_req_control_data(TALLOC_CTX *mem_ctx,
|
||||
case CTDB_CONTROL_GET_DBMAP:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
cd->data.pulldb = talloc(mem_ctx, struct ctdb_pulldb);
|
||||
assert(cd->data.pulldb != NULL);
|
||||
fill_ctdb_pulldb(mem_ctx, cd->data.pulldb);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
cd->data.recbuf = talloc(mem_ctx, struct ctdb_rec_buffer);
|
||||
assert(cd->data.recbuf != NULL);
|
||||
fill_ctdb_rec_buffer(mem_ctx, cd->data.recbuf);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_GET_RECMODE:
|
||||
break;
|
||||
|
||||
@ -646,14 +634,6 @@ void verify_ctdb_req_control_data(struct ctdb_req_control_data *cd,
|
||||
case CTDB_CONTROL_GET_DBMAP:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
verify_ctdb_pulldb(cd->data.pulldb, cd2->data.pulldb);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
verify_ctdb_rec_buffer(cd->data.recbuf, cd2->data.recbuf);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_GET_RECMODE:
|
||||
break;
|
||||
|
||||
@ -1077,15 +1057,6 @@ void fill_ctdb_reply_control_data(TALLOC_CTX *mem_ctx,
|
||||
fill_ctdb_dbid_map(mem_ctx, cd->data.dbmap);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
cd->data.recbuf = talloc(mem_ctx, struct ctdb_rec_buffer);
|
||||
assert(cd->data.recbuf != NULL);
|
||||
fill_ctdb_rec_buffer(mem_ctx, cd->data.recbuf);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_GET_RECMODE:
|
||||
break;
|
||||
|
||||
@ -1450,13 +1421,6 @@ void verify_ctdb_reply_control_data(struct ctdb_reply_control_data *cd,
|
||||
verify_ctdb_dbid_map(cd->data.dbmap, cd2->data.dbmap);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PULL_DB:
|
||||
verify_ctdb_rec_buffer(cd->data.recbuf, cd2->data.recbuf);
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_PUSH_DB:
|
||||
break;
|
||||
|
||||
case CTDB_CONTROL_GET_RECMODE:
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user