return status;
}
-struct catia_get_dos_attributes_state {
- struct vfs_aio_state aio_state;
- struct catia_cache *cc;
- files_struct *dir_fsp;
- uint32_t dosmode;
-};
-
-static void catia_get_dos_attributes_done(struct tevent_req *subreq);
-
-static struct tevent_req *catia_get_dos_attributes_send(
- struct vfs_handle_struct *handle,
- TALLOC_CTX *mem_ctx,
- const struct smb_vfs_ev_glue *evg,
- files_struct *dir_fsp,
- struct smb_filename *smb_fname)
-{
- struct tevent_context *ev = smb_vfs_ev_glue_ev_ctx(evg);
- struct tevent_req *req = NULL;
- struct tevent_req *subreq = NULL;
- struct catia_get_dos_attributes_state *state = NULL;
- char *mapped_name = NULL;
- struct smb_filename *mapped_smb_fname = NULL;
- NTSTATUS status;
- int ret;
-
- req = tevent_req_create(mem_ctx, &state,
- struct catia_get_dos_attributes_state);
- if (req == NULL) {
- return NULL;
- }
- state->dir_fsp = dir_fsp;
-
- ret = CATIA_FETCH_FSP_PRE_NEXT(state, handle, dir_fsp, &state->cc);
- if (ret != 0) {
- tevent_req_error(req, errno);
- return tevent_req_post(req, ev);
- }
-
- status = catia_string_replace_allocate(handle->conn,
- smb_fname->base_name,
- &mapped_name,
- vfs_translate_to_unix);
- if (!NT_STATUS_IS_OK(status)) {
- errno = map_errno_from_nt_status(status);
- tevent_req_error(req, errno);
- return tevent_req_post(req, ev);
- }
-
- mapped_smb_fname = synthetic_smb_fname(talloc_tos(),
- mapped_name,
- NULL,
- NULL,
- smb_fname->flags);
- if (mapped_smb_fname == NULL) {
- TALLOC_FREE(mapped_name);
- tevent_req_error(req, ENOMEM);
- return tevent_req_post(req, ev);
- }
-
- subreq = SMB_VFS_NEXT_GET_DOS_ATTRIBUTES_SEND(handle,
- mem_ctx,
- evg,
- dir_fsp,
- smb_fname);
- if (tevent_req_nomem(subreq, req)) {
- return tevent_req_post(req, ev);
- }
- tevent_req_set_callback(
- subreq, catia_get_dos_attributes_done, req);
-
- return req;
-}
-
-static void catia_get_dos_attributes_done(struct tevent_req *subreq)
-{
- struct tevent_req *req = tevent_req_callback_data(
- subreq, struct tevent_req);
- struct catia_get_dos_attributes_state *state = tevent_req_data(
- req, struct catia_get_dos_attributes_state);
- NTSTATUS status;
-
- status = SMB_VFS_NEXT_GET_DOS_ATTRIBUTES_RECV(subreq,
- &state->aio_state,
- &state->dosmode);
- TALLOC_FREE(subreq);
- CATIA_FETCH_FSP_POST_NEXT(&state->cc, state->dir_fsp);
- if (tevent_req_nterror(req, status)) {
- return;
- }
-
- tevent_req_done(req);
- return;
-}
-
-static NTSTATUS catia_get_dos_attributes_recv(struct tevent_req *req,
- struct vfs_aio_state *aio_state,
- uint32_t *dosmode)
-{
- struct catia_get_dos_attributes_state *state = tevent_req_data(
- req, struct catia_get_dos_attributes_state);
- NTSTATUS status;
-
- if (tevent_req_is_nterror(req, &status)) {
- tevent_req_received(req);
- return status;
- }
-
- *aio_state = state->aio_state;
- *dosmode = state->dosmode;
- tevent_req_received(req);
- return NT_STATUS_OK;
-}
-
static NTSTATUS catia_set_dos_attributes(struct vfs_handle_struct *handle,
const struct smb_filename *smb_fname,
uint32_t dosmode)
.translate_name_fn = catia_translate_name,
.fsctl_fn = catia_fsctl,
.get_dos_attributes_fn = catia_get_dos_attributes,
- .get_dos_attributes_send_fn = catia_get_dos_attributes_send,
- .get_dos_attributes_recv_fn = catia_get_dos_attributes_recv,
+ .get_dos_attributes_send_fn = vfs_not_implemented_get_dos_attributes_send,
+ .get_dos_attributes_recv_fn = vfs_not_implemented_get_dos_attributes_recv,
.set_dos_attributes_fn = catia_set_dos_attributes,
.fset_dos_attributes_fn = catia_fset_dos_attributes,
.fget_dos_attributes_fn = catia_fget_dos_attributes,