diff options
author | Stefan Metzmacher <metze@samba.org> | 2012-04-24 13:49:52 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2012-04-24 16:43:03 +0200 |
commit | 84ae92da6ba4a060bd53cb73c83a86c0cc699115 (patch) | |
tree | 73b61d4fb37b7b81364be2dc0e4f779dfeded96a /source4/libnet | |
parent | d38a171a43d3298d64adfa2a2869e84e560d3107 (diff) | |
download | samba-84ae92da6ba4a060bd53cb73c83a86c0cc699115.tar.gz samba-84ae92da6ba4a060bd53cb73c83a86c0cc699115.tar.bz2 samba-84ae92da6ba4a060bd53cb73c83a86c0cc699115.zip |
s4:libnet: pass an explicit mem_ctx to libnet_rpc_userinfo_send() (bug #8889)
This hopefully fixes the flakey autobuild.
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Apr 24 16:43:03 CEST 2012 on sn-devel-104
Diffstat (limited to 'source4/libnet')
-rw-r--r-- | source4/libnet/libnet_user.c | 8 | ||||
-rw-r--r-- | source4/libnet/userinfo.c | 5 |
2 files changed, 8 insertions, 5 deletions
diff --git a/source4/libnet/libnet_user.c b/source4/libnet/libnet_user.c index dc0691ac22..eef480af4a 100644 --- a/source4/libnet/libnet_user.c +++ b/source4/libnet/libnet_user.c @@ -423,7 +423,7 @@ struct composite_context *libnet_ModifyUser_send(struct libnet_context *ctx, s->user_info.in.domain_handle = ctx->samr.handle; s->user_info.in.level = level; - userinfo_req = libnet_rpc_userinfo_send(ctx->samr.pipe, &s->user_info, monitor); + userinfo_req = libnet_rpc_userinfo_send(ctx->samr.pipe, s, &s->user_info, monitor); if (composite_nomem(userinfo_req, c)) return c; composite_continue(c, userinfo_req, continue_rpc_userinfo, c); @@ -455,7 +455,7 @@ static void continue_domain_open_modify(struct composite_context *ctx) s->user_info.in.username = s->r.in.user_name; s->user_info.in.level = level; - userinfo_req = libnet_rpc_userinfo_send(s->ctx->samr.pipe, &s->user_info, s->monitor_fn); + userinfo_req = libnet_rpc_userinfo_send(s->ctx->samr.pipe, s, &s->user_info, s->monitor_fn); if (composite_nomem(userinfo_req, c)) return; composite_continue(c, userinfo_req, continue_rpc_userinfo, c); @@ -687,6 +687,7 @@ struct composite_context* libnet_UserInfo_send(struct libnet_context *ctx, /* send the request */ info_req = libnet_rpc_userinfo_send(s->ctx->samr.pipe, + s, &s->userinfo, s->monitor_fn); if (composite_nomem(info_req, c)) return c; @@ -743,6 +744,7 @@ static void continue_domain_open_info(struct composite_context *ctx) /* send the request */ info_req = libnet_rpc_userinfo_send(s->ctx->samr.pipe, + s, &s->userinfo, s->monitor_fn); if (composite_nomem(info_req, c)) return; @@ -782,7 +784,7 @@ static void continue_name_found(struct composite_context *ctx) s->userinfo.in.level = 21; /* send the request */ - info_req = libnet_rpc_userinfo_send(s->ctx->samr.pipe, &s->userinfo, s->monitor_fn); + info_req = libnet_rpc_userinfo_send(s->ctx->samr.pipe, s, &s->userinfo, s->monitor_fn); if (composite_nomem(info_req, c)) return; /* set the next stage */ diff --git a/source4/libnet/userinfo.c b/source4/libnet/userinfo.c index ddb249ee96..75c46e477d 100644 --- a/source4/libnet/userinfo.c +++ b/source4/libnet/userinfo.c @@ -260,6 +260,7 @@ static void continue_userinfo_closeuser(struct tevent_req *subreq) * @param io arguments and results of the call */ struct composite_context *libnet_rpc_userinfo_send(struct dcerpc_pipe *p, + TALLOC_CTX *mem_ctx, struct libnet_rpc_userinfo *io, void (*monitor)(struct monitor_msg*)) { @@ -270,7 +271,7 @@ struct composite_context *libnet_rpc_userinfo_send(struct dcerpc_pipe *p, if (!p || !io) return NULL; - c = composite_create(p, dcerpc_event_context(p)); + c = composite_create(mem_ctx, dcerpc_event_context(p)); if (c == NULL) return c; s = talloc_zero(c, struct userinfo_state); @@ -370,6 +371,6 @@ NTSTATUS libnet_rpc_userinfo(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, struct libnet_rpc_userinfo *io) { - struct composite_context *c = libnet_rpc_userinfo_send(p, io, NULL); + struct composite_context *c = libnet_rpc_userinfo_send(p, mem_ctx, io, NULL); return libnet_rpc_userinfo_recv(c, mem_ctx, io); } |