summaryrefslogtreecommitdiff
path: root/source3/modules/vfs_media_harmony.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2017-05-19 16:15:55 -0700
committerJeremy Allison <jra@samba.org>2017-06-18 02:49:24 +0200
commit730de8e091879a53493a0c96b542603cd52174a2 (patch)
treeb5f84772da7675c5bc86d37d9dd3bc53796e078f /source3/modules/vfs_media_harmony.c
parentc3d45216dd7df2a084b7d1af63f207db0c87b53d (diff)
downloadsamba-730de8e091879a53493a0c96b542603cd52174a2.tar.gz
s3: VFS: Change SMB_VFS_CHFLAGS to use const struct smb_filename * instead of const char *.
We need to migrate all pathname based VFS calls to use a struct to finish modernising the VFS with extra timestamp and flags parameters. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Richard Sharpe <realrichardsharpe@gmail.com>
Diffstat (limited to 'source3/modules/vfs_media_harmony.c')
-rw-r--r--source3/modules/vfs_media_harmony.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/source3/modules/vfs_media_harmony.c b/source3/modules/vfs_media_harmony.c
index 99a5e9b6979..37b396a5bea 100644
--- a/source3/modules/vfs_media_harmony.c
+++ b/source3/modules/vfs_media_harmony.c
@@ -1923,33 +1923,30 @@ out:
* Failure: set errno, return -1
*/
static int mh_chflags(vfs_handle_struct *handle,
- const char *path,
+ const struct smb_filename *smb_fname,
unsigned int flags)
{
int status;
- char *clientPath;
+ struct smb_filename *clientFname = NULL;
TALLOC_CTX *ctx;
DEBUG(MH_INFO_DEBUG, ("Entering mh_chflags\n"));
- if (!is_in_media_files(path))
- {
- status = SMB_VFS_NEXT_CHFLAGS(handle, path, flags);
+ if (!is_in_media_files(smb_fname->base_name)) {
+ status = SMB_VFS_NEXT_CHFLAGS(handle, smb_fname, flags);
goto out;
}
- clientPath = NULL;
ctx = talloc_tos();
- if ((status = alloc_get_client_path(handle, ctx,
- path,
- &clientPath)))
- {
+ if ((status = alloc_get_client_smb_fname(handle, ctx,
+ smb_fname,
+ &clientFname))) {
goto err;
}
- status = SMB_VFS_NEXT_CHFLAGS(handle, clientPath, flags);
+ status = SMB_VFS_NEXT_CHFLAGS(handle, clientFname, flags);
err:
- TALLOC_FREE(clientPath);
+ TALLOC_FREE(clientFname);
out:
return status;
}