s3: libsmb: Add uint16_t addtional_flags2 to cli_smb_req_create().
authorJeremy Allison <jra@samba.org>
Thu, 18 Aug 2016 20:45:35 +0000 (13:45 -0700)
committerUri Simchoni <uri@samba.org>
Fri, 19 Aug 2016 18:03:12 +0000 (20:03 +0200)
Not yet used.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12165

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>
source3/include/async_smb.h
source3/libsmb/async_smb.c
source3/libsmb/cliconnect.c
source3/libsmb/clifile.c
source3/libsmb/clireadwrite.c

index 676574972825f2b103b4221a41f1d0586e7d86d2..3c64d082982e8a09d3dba4ceb75a2ed86eb771e7 100644 (file)
@@ -27,6 +27,7 @@ struct tevent_req *cli_smb_req_create(TALLOC_CTX *mem_ctx,
                                      struct cli_state *cli,
                                      uint8_t smb_command,
                                      uint8_t additional_flags,
+                                     uint16_t additional_flags2,
                                      uint8_t wct, uint16_t *vwv,
                                      int iov_count,
                                      struct iovec *bytes_iov);
index 5d9cce12272b380275d71f5a441890ea0741c0a1..bcb24a479437bdc753589c3301e41e4d27d2eeb6 100644 (file)
@@ -54,13 +54,13 @@ struct tevent_req *cli_smb_req_create(TALLOC_CTX *mem_ctx,
                                      struct cli_state *cli,
                                      uint8_t smb_command,
                                      uint8_t additional_flags,
+                                     uint16_t additional_flags2,
                                      uint8_t wct, uint16_t *vwv,
                                      int iov_count,
                                      struct iovec *bytes_iov)
 {
        struct cli_smb_req_state *state;
        uint8_t clear_flags = 0;
-       uint16_t additional_flags2 = 0;
        uint16_t clear_flags2 = 0;
 
        state = talloc_zero(mem_ctx, struct cli_smb_req_state);
index 4635cf8cad678349d1c4230ae7fd6ca238d26f31..9c8851f76564092100921028afe3fd1dc78c5f21 100644 (file)
@@ -386,8 +386,8 @@ struct tevent_req *cli_session_setup_guest_create(TALLOC_CTX *mem_ctx,
        state->bytes.iov_base = (void *)bytes;
        state->bytes.iov_len = talloc_get_size(bytes);
 
-       subreq = cli_smb_req_create(state, ev, cli, SMBsesssetupX, 0, 13, vwv,
-                                   1, &state->bytes);
+       subreq = cli_smb_req_create(state, ev, cli, SMBsesssetupX, 0, 0, 13,
+                       vwv, 1, &state->bytes);
        if (subreq == NULL) {
                TALLOC_FREE(req);
                return NULL;
@@ -2549,7 +2549,7 @@ struct tevent_req *cli_tcon_andx_create(TALLOC_CTX *mem_ctx,
        state->bytes.iov_base = (void *)bytes;
        state->bytes.iov_len = talloc_get_size(bytes);
 
-       subreq = cli_smb_req_create(state, ev, cli, SMBtconX, 0, 4, vwv,
+       subreq = cli_smb_req_create(state, ev, cli, SMBtconX, 0, 0, 4, vwv,
                                    1, &state->bytes);
        if (subreq == NULL) {
                TALLOC_FREE(req);
index e8c16c1f86dca672059c93a9398810fa2fd214ff..bc96015904535d4064d1994dd570ba853c456b68 100644 (file)
@@ -2464,7 +2464,7 @@ struct tevent_req *cli_openx_create(TALLOC_CTX *mem_ctx,
        state->bytes.iov_len = talloc_get_size(bytes);
 
        subreq = cli_smb_req_create(state, ev, cli, SMBopenX, additional_flags,
-                                   15, state->vwv, 1, &state->bytes);
+                                   0, 15, state->vwv, 1, &state->bytes);
        if (subreq == NULL) {
                TALLOC_FREE(req);
                return NULL;
@@ -2726,8 +2726,8 @@ struct tevent_req *cli_close_create(TALLOC_CTX *mem_ctx,
        SSVAL(state->vwv+0, 0, fnum);
        SIVALS(state->vwv+1, 0, -1);
 
-       subreq = cli_smb_req_create(state, ev, cli, SMBclose, 0, 3, state->vwv,
-                                   0, NULL);
+       subreq = cli_smb_req_create(state, ev, cli, SMBclose, 0, 0,
+                               3, state->vwv, 0, NULL);
        if (subreq == NULL) {
                TALLOC_FREE(req);
                return NULL;
index 35141540e6209b14e333534c29dde13397499bcf..1c32d2a9c67cdb559ed42fbb0f8924b2c6691de8 100644 (file)
@@ -162,7 +162,7 @@ struct tevent_req *cli_read_andx_create(TALLOC_CTX *mem_ctx,
                }
        }
 
-       subreq = cli_smb_req_create(state, ev, cli, SMBreadX, 0, wct,
+       subreq = cli_smb_req_create(state, ev, cli, SMBreadX, 0, 0, wct,
                                    state->vwv, 0, NULL);
        if (subreq == NULL) {
                TALLOC_FREE(req);
@@ -863,7 +863,7 @@ struct tevent_req *cli_write_andx_create(TALLOC_CTX *mem_ctx,
        state->iov[1].iov_base = discard_const_p(void, buf);
        state->iov[1].iov_len = state->size;
 
-       subreq = cli_smb_req_create(state, ev, cli, SMBwriteX, 0, wct, vwv,
+       subreq = cli_smb_req_create(state, ev, cli, SMBwriteX, 0, 0, wct, vwv,
                                    2, state->iov);
        if (tevent_req_nomem(subreq, req)) {
                return tevent_req_post(req, ev);