summaryrefslogtreecommitdiff
path: root/source4/libcli/composite/fetchfile.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-01-31 08:30:44 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:09:25 -0500
commit9a70f446fc4abc2bd1278772810c0e8132f4bea4 (patch)
treeb9baaa7b19c88afaa26f0cd0a35201fb5c433a3d /source4/libcli/composite/fetchfile.c
parent58d6c73e946d11574a6220f37887e1cdfe05f525 (diff)
downloadsamba-9a70f446fc4abc2bd1278772810c0e8132f4bea4.tar.gz
samba-9a70f446fc4abc2bd1278772810c0e8132f4bea4.tar.bz2
samba-9a70f446fc4abc2bd1278772810c0e8132f4bea4.zip
r5126: the composite code is no longer client specific or smb specific, so
rename the core structure to composite_context and the wait routine to composite_wait() (suggestion from metze) (This used to be commit cf11d05e35179c2c3e51c5ab370cd0a3fb15f24a)
Diffstat (limited to 'source4/libcli/composite/fetchfile.c')
-rw-r--r--source4/libcli/composite/fetchfile.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/source4/libcli/composite/fetchfile.c b/source4/libcli/composite/fetchfile.c
index 8178090398..4f63f6328f 100644
--- a/source4/libcli/composite/fetchfile.c
+++ b/source4/libcli/composite/fetchfile.c
@@ -32,14 +32,14 @@ enum fetchfile_stage {FETCHFILE_CONNECT,
struct fetchfile_state {
enum fetchfile_stage stage;
struct smb_composite_fetchfile *io;
- struct smbcli_composite *req;
+ struct composite_context *req;
struct smb_composite_connect *connect;
struct smb_composite_loadfile *loadfile;
};
-static void fetchfile_composite_handler(struct smbcli_composite *req);
+static void fetchfile_composite_handler(struct composite_context *req);
-static NTSTATUS fetchfile_connect(struct smbcli_composite *c,
+static NTSTATUS fetchfile_connect(struct composite_context *c,
struct smb_composite_fetchfile *io)
{
NTSTATUS status;
@@ -67,7 +67,7 @@ static NTSTATUS fetchfile_connect(struct smbcli_composite *c,
return NT_STATUS_OK;
}
-static NTSTATUS fetchfile_read(struct smbcli_composite *c,
+static NTSTATUS fetchfile_read(struct composite_context *c,
struct smb_composite_fetchfile *io)
{
NTSTATUS status;
@@ -87,7 +87,7 @@ static NTSTATUS fetchfile_read(struct smbcli_composite *c,
return NT_STATUS_OK;
}
-static void fetchfile_state_handler(struct smbcli_composite *c)
+static void fetchfile_state_handler(struct composite_context *c)
{
struct fetchfile_state *state;
NTSTATUS status;
@@ -114,20 +114,20 @@ static void fetchfile_state_handler(struct smbcli_composite *c)
}
}
-static void fetchfile_composite_handler(struct smbcli_composite *req)
+static void fetchfile_composite_handler(struct composite_context *req)
{
- struct smbcli_composite *c = talloc_get_type(req->async.private,
- struct smbcli_composite);
+ struct composite_context *c = talloc_get_type(req->async.private,
+ struct composite_context);
return fetchfile_state_handler(c);
}
-struct smbcli_composite *smb_composite_fetchfile_send(struct smb_composite_fetchfile *io,
+struct composite_context *smb_composite_fetchfile_send(struct smb_composite_fetchfile *io,
struct event_context *event_ctx)
{
- struct smbcli_composite *c;
+ struct composite_context *c;
struct fetchfile_state *state;
- c = talloc_zero(NULL, struct smbcli_composite);
+ c = talloc_zero(NULL, struct composite_context);
if (c == NULL) goto failed;
state = talloc(c, struct fetchfile_state);
@@ -165,12 +165,12 @@ struct smbcli_composite *smb_composite_fetchfile_send(struct smb_composite_fetch
return NULL;
}
-NTSTATUS smb_composite_fetchfile_recv(struct smbcli_composite *c,
+NTSTATUS smb_composite_fetchfile_recv(struct composite_context *c,
TALLOC_CTX *mem_ctx)
{
NTSTATUS status;
- status = smb_composite_wait(c);
+ status = composite_wait(c);
if (NT_STATUS_IS_OK(status)) {
struct fetchfile_state *state = talloc_get_type(c->private, struct fetchfile_state);
@@ -184,6 +184,6 @@ NTSTATUS smb_composite_fetchfile_recv(struct smbcli_composite *c,
NTSTATUS smb_composite_fetchfile(struct smb_composite_fetchfile *io,
TALLOC_CTX *mem_ctx)
{
- struct smbcli_composite *c = smb_composite_fetchfile_send(io, NULL);
+ struct composite_context *c = smb_composite_fetchfile_send(io, NULL);
return smb_composite_fetchfile_recv(c, mem_ctx);
}