From: Jeremy Allison Date: Wed, 3 Jun 2020 21:07:21 +0000 (-0700) Subject: s3: libsmb: Make cli_list_trans() and cli_list take a 32-bit attribute. X-Git-Tag: ldb-2.2.0~201 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fe3879b3c92b0c82c469bb00d916e3840eb7b8e9;p=thirdparty%2Fsamba.git s3: libsmb: Make cli_list_trans() and cli_list take a 32-bit attribute. All sub-functions take 32-bits, and all callers now are compatible with 32-bit attributes. Signed-off-by: Jeremy Allison Reviewed-by: Volker Lendecke --- diff --git a/source3/libsmb/clilist.c b/source3/libsmb/clilist.c index b453900b3f4..3a0c10e55b0 100644 --- a/source3/libsmb/clilist.c +++ b/source3/libsmb/clilist.c @@ -617,7 +617,7 @@ struct cli_list_trans_state { struct tevent_context *ev; struct cli_state *cli; char *mask; - uint16_t attribute; + uint32_t attribute; uint16_t info_level; int loop_count; @@ -640,7 +640,7 @@ static struct tevent_req *cli_list_trans_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli, const char *mask, - uint16_t attribute, + uint32_t attribute, uint16_t info_level) { struct tevent_req *req, *subreq; @@ -921,7 +921,7 @@ static NTSTATUS cli_list_trans_recv(struct tevent_req *req, } NTSTATUS cli_list_trans(struct cli_state *cli, const char *mask, - uint16_t attribute, int info_level, + uint32_t attribute, int info_level, NTSTATUS (*fn)(const char *mnt, struct file_info *finfo, const char *mask, void *private_data), void *private_data) @@ -979,7 +979,7 @@ struct tevent_req *cli_list_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli, const char *mask, - uint16_t attribute, + uint32_t attribute, uint16_t info_level) { struct tevent_req *req, *subreq; @@ -1037,7 +1037,7 @@ NTSTATUS cli_list_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, return NT_STATUS_OK; } -NTSTATUS cli_list(struct cli_state *cli, const char *mask, uint16_t attribute, +NTSTATUS cli_list(struct cli_state *cli, const char *mask, uint32_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state) { diff --git a/source3/libsmb/proto.h b/source3/libsmb/proto.h index 734f4749b5b..bbc3d6efa03 100644 --- a/source3/libsmb/proto.h +++ b/source3/libsmb/proto.h @@ -759,7 +759,7 @@ NTSTATUS cli_list_old(struct cli_state *cli,const char *Mask,uint32_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state); NTSTATUS cli_list_trans(struct cli_state *cli, const char *mask, - uint16_t attribute, int info_level, + uint32_t attribute, int info_level, NTSTATUS (*fn)(const char *mnt, struct file_info *finfo, const char *mask, void *private_data), void *private_data); @@ -767,11 +767,11 @@ struct tevent_req *cli_list_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct cli_state *cli, const char *mask, - uint16_t attribute, + uint32_t attribute, uint16_t info_level); NTSTATUS cli_list_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, struct file_info **finfo, size_t *num_finfo); -NTSTATUS cli_list(struct cli_state *cli,const char *Mask,uint16_t attribute, +NTSTATUS cli_list(struct cli_state *cli,const char *Mask,uint32_t attribute, NTSTATUS (*fn)(const char *, struct file_info *, const char *, void *), void *state);