diff --git a/source3/smbd/smb2_flush.c b/source3/smbd/smb2_flush.c index e73666f0afc..80a47913322 100644 --- a/source3/smbd/smb2_flush.c +++ b/source3/smbd/smb2_flush.c @@ -126,6 +126,7 @@ static struct tevent_req *smbd_smb2_flush_send(TALLOC_CTX *mem_ctx, struct tevent_req *subreq; struct smbd_smb2_flush_state *state; struct smb_request *smbreq; + bool is_compound = false; req = tevent_req_create(mem_ctx, &state, struct smbd_smb2_flush_state); @@ -188,6 +189,11 @@ static struct tevent_req *smbd_smb2_flush_send(TALLOC_CTX *mem_ctx, return tevent_req_post(req, ev); } + is_compound = smbd_smb2_is_compound(smb2req); + if (is_compound) { + smb2_request_set_async_internal(smb2req, true); + } + subreq = SMB_VFS_FSYNC_SEND(state, ev, fsp); if (tevent_req_nomem(subreq, req)) { return tevent_req_post(req, ev); diff --git a/source3/smbd/smb2_ioctl.c b/source3/smbd/smb2_ioctl.c index e4f8c10e3af..9b0de6553ec 100644 --- a/source3/smbd/smb2_ioctl.c +++ b/source3/smbd/smb2_ioctl.c @@ -427,6 +427,7 @@ static struct tevent_req *smbd_smb2_ioctl_send(TALLOC_CTX *mem_ctx, struct tevent_req *req; struct smbd_smb2_ioctl_state *state; struct smb_request *smbreq; + bool is_compound = false; req = tevent_req_create(mem_ctx, &state, struct smbd_smb2_ioctl_state); @@ -451,6 +452,11 @@ static struct tevent_req *smbd_smb2_ioctl_send(TALLOC_CTX *mem_ctx, } state->smbreq = smbreq; + is_compound = smbd_smb2_is_compound(smb2req); + if (is_compound) { + smb2_request_set_async_internal(smb2req, true); + } + switch (in_ctl_code & IOCTL_DEV_TYPE_MASK) { case FSCTL_DFS: return smb2_ioctl_dfs(in_ctl_code, ev, req, state);