summaryrefslogtreecommitdiff
path: root/source3/lib/wbclient.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2009-01-19 13:39:54 +1100
committerAndrew Bartlett <abartlet@samba.org>2009-01-19 13:39:54 +1100
commitd6e801b7d9a666d40f109df20dff0faaa2b46e70 (patch)
tree77d5e6ac67825eca5b8c970f6bfba95d8002f024 /source3/lib/wbclient.c
parent9fa6fb3d9fb2e4cee81ad34d6fd0cbe6f5265171 (diff)
parentfe9dd8710d577478b324d1d507de0ecd77df2ea5 (diff)
downloadsamba-d6e801b7d9a666d40f109df20dff0faaa2b46e70.tar.gz
samba-d6e801b7d9a666d40f109df20dff0faaa2b46e70.tar.bz2
samba-d6e801b7d9a666d40f109df20dff0faaa2b46e70.zip
Merge branch 'master' of ssh://git.samba.org/data/git/samba into abartlet-devel
Diffstat (limited to 'source3/lib/wbclient.c')
-rw-r--r--source3/lib/wbclient.c29
1 files changed, 6 insertions, 23 deletions
diff --git a/source3/lib/wbclient.c b/source3/lib/wbclient.c
index d58c934c07..ea0bcb512e 100644
--- a/source3/lib/wbclient.c
+++ b/source3/lib/wbclient.c
@@ -289,15 +289,10 @@ static struct async_req *wb_int_trans_send(TALLOC_CTX *mem_ctx,
struct async_req *subreq;
struct wb_int_trans_state *state;
- result = async_req_new(mem_ctx);
- if (result == NULL) {
+ if (!async_req_setup(mem_ctx, &result, &state,
+ struct wb_int_trans_state)) {
return NULL;
}
- state = talloc(result, struct wb_int_trans_state);
- if (state == NULL) {
- goto fail;
- }
- result->private_data = state;
if (winbind_closed_fd(fd)) {
if (!async_post_status(result, ev,
@@ -420,16 +415,10 @@ static struct async_req *wb_open_pipe_send(TALLOC_CTX *mem_ctx,
struct async_req *subreq;
struct wb_open_pipe_state *state;
- result = async_req_new(mem_ctx);
- if (result == NULL) {
+ if (!async_req_setup(mem_ctx, &result, &state,
+ struct wb_open_pipe_state)) {
return NULL;
}
- state = talloc(result, struct wb_open_pipe_state);
- if (state == NULL) {
- goto fail;
- }
- result->private_data = state;
-
state->wb_ctx = wb_ctx;
state->ev = ev;
state->need_priv = need_priv;
@@ -617,16 +606,10 @@ struct async_req *wb_trans_send(TALLOC_CTX *mem_ctx, struct event_context *ev,
struct async_req *result;
struct wb_trans_state *state;
- result = async_req_new(mem_ctx);
- if (result == NULL) {
+ if (!async_req_setup(mem_ctx, &result, &state,
+ struct wb_trans_state)) {
return NULL;
}
- state = talloc(result, struct wb_trans_state);
- if (state == NULL) {
- goto fail;
- }
- result->private_data = state;
-
state->wb_ctx = wb_ctx;
state->ev = ev;
state->wb_req = winbindd_request_copy(state, wb_req);