Skip to content

Commit

Permalink
s3: libsmb: Plumb in additional_flags2 = FLAGS2_REPARSE_PATH to cli_o…
Browse files Browse the repository at this point in the history
…penx_create().

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

Signed-off-by: Jeremy Allison <[email protected]>
Reviewed-by: Uri Simchoni <[email protected]>
  • Loading branch information
jrasamba authored and urisimchoni committed Aug 19, 2016
1 parent d7ee917 commit 47c1314
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion source3/libsmb/clifile.c
Original file line number Diff line number Diff line change
Expand Up @@ -2440,6 +2440,7 @@ struct tevent_req *cli_openx_create(TALLOC_CTX *mem_ctx,
unsigned openfn;
unsigned accessmode;
uint8_t additional_flags;
uint16_t additional_flags2 = 0;
uint8_t *bytes;

req = tevent_req_create(mem_ctx, &state, struct cli_openx_state);
Expand Down Expand Up @@ -2507,11 +2508,15 @@ struct tevent_req *cli_openx_create(TALLOC_CTX *mem_ctx,
return tevent_req_post(req, ev);
}

if (clistr_is_previous_version_path(fname)) {
additional_flags2 = FLAGS2_REPARSE_PATH;
}

state->bytes.iov_base = (void *)bytes;
state->bytes.iov_len = talloc_get_size(bytes);

subreq = cli_smb_req_create(state, ev, cli, SMBopenX, additional_flags,
0, 15, state->vwv, 1, &state->bytes);
additional_flags2, 15, state->vwv, 1, &state->bytes);
if (subreq == NULL) {
TALLOC_FREE(req);
return NULL;
Expand Down

0 comments on commit 47c1314

Please sign in to comment.