summaryrefslogtreecommitdiff
path: root/source4/libcli/smb_composite
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2012-04-25 16:26:50 +1000
committerAndrew Bartlett <abartlet@samba.org>2012-04-25 17:43:23 +1000
commite346bba1fc369cc13438cf3882961ef7b11ccc3a (patch)
treeb46e48b57095e76ff9ea614f23c9c2bad2d045cc /source4/libcli/smb_composite
parent594e3161810ba5a57ce5a3c88a8cd89b11d04650 (diff)
downloadsamba-e346bba1fc369cc13438cf3882961ef7b11ccc3a.tar.gz
samba-e346bba1fc369cc13438cf3882961ef7b11ccc3a.tar.bz2
samba-e346bba1fc369cc13438cf3882961ef7b11ccc3a.zip
s4-torture: enable raw.composite test again, and convert to new style test
This test has been skipped for some time, but is an important test for parallel operation. Andrew Bartlett
Diffstat (limited to 'source4/libcli/smb_composite')
-rw-r--r--source4/libcli/smb_composite/fsinfo.c13
-rw-r--r--source4/libcli/smb_composite/smb_composite.h6
2 files changed, 13 insertions, 6 deletions
diff --git a/source4/libcli/smb_composite/fsinfo.c b/source4/libcli/smb_composite/fsinfo.c
index 6537ef8c92..242e2cc445 100644
--- a/source4/libcli/smb_composite/fsinfo.c
+++ b/source4/libcli/smb_composite/fsinfo.c
@@ -127,7 +127,8 @@ static void fsinfo_composite_handler(struct composite_context *creq)
*/
struct composite_context *smb_composite_fsinfo_send(struct smbcli_tree *tree,
struct smb_composite_fsinfo *io,
- struct resolve_context *resolve_ctx)
+ struct resolve_context *resolve_ctx,
+ struct tevent_context *event_ctx)
{
struct composite_context *c;
struct fsinfo_state *state;
@@ -135,12 +136,15 @@ struct composite_context *smb_composite_fsinfo_send(struct smbcli_tree *tree,
c = talloc_zero(tree, struct composite_context);
if (c == NULL) goto failed;
+ c->event_ctx = event_ctx;
+ if (c->event_ctx == NULL) goto failed;
+
state = talloc(c, struct fsinfo_state);
if (state == NULL) goto failed;
state->io = io;
- state->connect = talloc(state, struct smb_composite_connect);
+ state->connect = talloc_zero(state, struct smb_composite_connect);
if (state->connect == NULL) goto failed;
@@ -201,9 +205,10 @@ NTSTATUS smb_composite_fsinfo_recv(struct composite_context *c, TALLOC_CTX *mem_
NTSTATUS smb_composite_fsinfo(struct smbcli_tree *tree,
TALLOC_CTX *mem_ctx,
struct smb_composite_fsinfo *io,
- struct resolve_context *resolve_ctx)
+ struct resolve_context *resolve_ctx,
+ struct tevent_context *ev)
{
- struct composite_context *c = smb_composite_fsinfo_send(tree, io, resolve_ctx);
+ struct composite_context *c = smb_composite_fsinfo_send(tree, io, resolve_ctx, ev);
return smb_composite_fsinfo_recv(c, mem_ctx);
}
diff --git a/source4/libcli/smb_composite/smb_composite.h b/source4/libcli/smb_composite/smb_composite.h
index 54ee1ca836..a92c9612c6 100644
--- a/source4/libcli/smb_composite/smb_composite.h
+++ b/source4/libcli/smb_composite/smb_composite.h
@@ -187,12 +187,14 @@ struct smb_composite_fsinfo {
struct composite_context *smb_composite_fsinfo_send(struct smbcli_tree *tree,
struct smb_composite_fsinfo *io,
- struct resolve_context *resolve_ctx);
+ struct resolve_context *resolve_ctx,
+ struct tevent_context *event_ctx);
NTSTATUS smb_composite_fsinfo_recv(struct composite_context *c, TALLOC_CTX *mem_ctx);
NTSTATUS smb_composite_fsinfo(struct smbcli_tree *tree,
TALLOC_CTX *mem_ctx,
struct smb_composite_fsinfo *io,
- struct resolve_context *resolve_ctx);
+ struct resolve_context *resolve_ctx,
+ struct tevent_context *ev);
/*
composite call for appending new acl to the file's security descriptor and get