summaryrefslogtreecommitdiffstats
path: root/source4/libcli
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2014-02-02 15:45:13 +0100
committerAndreas Schneider <asn@cryptomilk.org>2014-03-05 16:33:21 +0100
commitdcf29a88bad40b4d22a71838d301e8a51a04d9e4 (patch)
treec2d9cf19bce8f1c509b8bd84a83955b6dbb16f3d /source4/libcli
parenteb8f4b846fe2d1ebf7e5a6adc0622aefe54993cb (diff)
downloadsamba-dcf29a88bad40b4d22a71838d301e8a51a04d9e4.tar.gz
samba-dcf29a88bad40b4d22a71838d301e8a51a04d9e4.tar.xz
samba-dcf29a88bad40b4d22a71838d301e8a51a04d9e4.zip
libwbclient4: Remove unused composite-based functions
Signed-off-by: Volker Lendecke <vl@samba.org> Change-Id: Iff6169e35f7a82e31c42df7b2d30d122b5f67451 Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
Diffstat (limited to 'source4/libcli')
-rw-r--r--source4/libcli/wbclient/wbclient.c142
-rw-r--r--source4/libcli/wbclient/wbclient.h16
2 files changed, 0 insertions, 158 deletions
diff --git a/source4/libcli/wbclient/wbclient.c b/source4/libcli/wbclient/wbclient.c
index 8cfe117d0b1..3f8003bbbaf 100644
--- a/source4/libcli/wbclient/wbclient.c
+++ b/source4/libcli/wbclient/wbclient.c
@@ -57,148 +57,6 @@ struct wbc_context *wbc_init(TALLOC_CTX *mem_ctx,
return ctx;
}
-struct wbc_idmap_state {
- struct composite_context *ctx;
- struct winbind_get_idmap *req;
- struct id_map *ids;
-};
-
-static void sids_to_xids_recv_ids(struct tevent_req *subreq);
-
-struct composite_context *wbc_sids_to_xids_send(struct wbc_context *wbc_ctx,
- TALLOC_CTX *mem_ctx,
- uint32_t count,
- struct id_map *ids)
-{
- struct composite_context *ctx;
- struct wbc_idmap_state *state;
- struct tevent_req *subreq;
-
- DEBUG(5, ("wbc_sids_to_xids called\n"));
-
- ctx = composite_create(mem_ctx, wbc_ctx->event_ctx);
- if (ctx == NULL) return NULL;
-
- state = talloc(ctx, struct wbc_idmap_state);
- if (composite_nomem(state, ctx)) return ctx;
- ctx->private_data = state;
-
- state->req = talloc(state, struct winbind_get_idmap);
- if (composite_nomem(state->req, ctx)) return ctx;
-
- state->req->in.count = count;
- state->req->in.level = WINBIND_IDMAP_LEVEL_SIDS_TO_XIDS;
- state->req->in.ids = ids;
- state->ctx = ctx;
-
- subreq = dcerpc_winbind_get_idmap_r_send(state,
- wbc_ctx->event_ctx,
- wbc_ctx->irpc_handle,
- state->req);
- if (composite_nomem(subreq, ctx)) return ctx;
-
- tevent_req_set_callback(subreq, sids_to_xids_recv_ids, state);
-
- return ctx;
-}
-
-static void sids_to_xids_recv_ids(struct tevent_req *subreq)
-{
- struct wbc_idmap_state *state =
- tevent_req_callback_data(subreq,
- struct wbc_idmap_state);
-
- state->ctx->status = dcerpc_winbind_get_idmap_r_recv(subreq, state);
- TALLOC_FREE(subreq);
- if (!composite_is_ok(state->ctx)) return;
-
- state->ids = state->req->out.ids;
- composite_done(state->ctx);
-}
-
-NTSTATUS wbc_sids_to_xids_recv(struct composite_context *ctx,
- struct id_map **ids)
-{
- NTSTATUS status = composite_wait(ctx);
- DEBUG(5, ("wbc_sids_to_xids_recv called\n"));
- if (NT_STATUS_IS_OK(status)) {
- struct wbc_idmap_state *state = talloc_get_type_abort(
- ctx->private_data,
- struct wbc_idmap_state);
- *ids = state->ids;
- }
-
- return status;
-}
-
-static void xids_to_sids_recv_ids(struct tevent_req *subreq);
-
-struct composite_context *wbc_xids_to_sids_send(struct wbc_context *wbc_ctx,
- TALLOC_CTX *mem_ctx,
- uint32_t count,
- struct id_map *ids)
-{
- struct composite_context *ctx;
- struct wbc_idmap_state *state;
- struct tevent_req *subreq;
-
- DEBUG(5, ("wbc_xids_to_sids called\n"));
-
- ctx = composite_create(mem_ctx, wbc_ctx->event_ctx);
- if (ctx == NULL) return NULL;
-
- state = talloc(ctx, struct wbc_idmap_state);
- if (composite_nomem(state, ctx)) return ctx;
- ctx->private_data = state;
-
- state->req = talloc(state, struct winbind_get_idmap);
- if (composite_nomem(state->req, ctx)) return ctx;
-
- state->req->in.count = count;
- state->req->in.level = WINBIND_IDMAP_LEVEL_XIDS_TO_SIDS;
- state->req->in.ids = ids;
- state->ctx = ctx;
-
- subreq = dcerpc_winbind_get_idmap_r_send(state,
- wbc_ctx->event_ctx,
- wbc_ctx->irpc_handle,
- state->req);
- if (composite_nomem(subreq, ctx)) return ctx;
-
- tevent_req_set_callback(subreq, xids_to_sids_recv_ids, state);
-
- return ctx;
-}
-
-static void xids_to_sids_recv_ids(struct tevent_req *subreq)
-{
- struct wbc_idmap_state *state =
- tevent_req_callback_data(subreq,
- struct wbc_idmap_state);
-
- state->ctx->status = dcerpc_winbind_get_idmap_r_recv(subreq, state);
- TALLOC_FREE(subreq);
- if (!composite_is_ok(state->ctx)) return;
-
- state->ids = state->req->out.ids;
- composite_done(state->ctx);
-}
-
-NTSTATUS wbc_xids_to_sids_recv(struct composite_context *ctx,
- struct id_map **ids)
-{
- NTSTATUS status = composite_wait(ctx);
- DEBUG(5, ("wbc_xids_to_sids_recv called\n"));
- if (NT_STATUS_IS_OK(status)) {
- struct wbc_idmap_state *state = talloc_get_type_abort(
- ctx->private_data,
- struct wbc_idmap_state);
- *ids = state->ids;
- }
-
- return status;
-}
-
static int wb_simple_trans(struct tevent_context *ev, int fd,
struct winbindd_request *wb_req,
TALLOC_CTX *mem_ctx,
diff --git a/source4/libcli/wbclient/wbclient.h b/source4/libcli/wbclient/wbclient.h
index 33a21f318d2..ba15a7c06df 100644
--- a/source4/libcli/wbclient/wbclient.h
+++ b/source4/libcli/wbclient/wbclient.h
@@ -31,24 +31,8 @@ struct wbc_context *wbc_init(TALLOC_CTX *mem_ctx,
struct imessaging_context *msg_ctx,
struct tevent_context *event_ctx);
-struct composite_context *wbc_sids_to_xids_send(struct wbc_context *wbc_ctx,
- TALLOC_CTX *mem_ctx,
- uint32_t count,
- struct id_map *ids);
-
-NTSTATUS wbc_sids_to_xids_recv(struct composite_context *ctx,
- struct id_map **ids);
-
NTSTATUS wbc_sids_to_xids(struct tevent_context *ev, struct id_map *ids,
uint32_t count);
-struct composite_context *wbc_xids_to_sids_send(struct wbc_context *wbc_ctx,
- TALLOC_CTX *mem_ctx,
- uint32_t count,
- struct id_map *ids);
-
-NTSTATUS wbc_xids_to_sids_recv(struct composite_context *ctx,
- struct id_map **ids);
-
NTSTATUS wbc_xids_to_sids(struct tevent_context *ev, struct id_map *ids,
uint32_t count);