From bd9285b19741128bae501b721d9e63dd9a9bd833 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Thu, 29 Jun 2017 14:32:47 -0700 Subject: s3: VFS: Change SMB_VFS_GETWD to return struct smb_filename * instead of 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 Reviewed-by: Richard Sharpe --- source3/modules/vfs_glusterfs.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'source3/modules/vfs_glusterfs.c') diff --git a/source3/modules/vfs_glusterfs.c b/source3/modules/vfs_glusterfs.c index 833f093ac42..52539b36fd9 100644 --- a/source3/modules/vfs_glusterfs.c +++ b/source3/modules/vfs_glusterfs.c @@ -1076,10 +1076,12 @@ static int vfs_gluster_chdir(struct vfs_handle_struct *handle, return glfs_chdir(handle->data, smb_fname->base_name); } -static char *vfs_gluster_getwd(struct vfs_handle_struct *handle) +static struct smb_filename *vfs_gluster_getwd(struct vfs_handle_struct *handle, + TALLOC_CTX *ctx) { char *cwd; char *ret; + struct smb_filename *smb_fname = NULL; cwd = SMB_CALLOC_ARRAY(char, PATH_MAX); if (cwd == NULL) { @@ -1090,7 +1092,13 @@ static char *vfs_gluster_getwd(struct vfs_handle_struct *handle) if (ret == 0) { free(cwd); } - return ret; + smb_fname = synthetic_smb_fname(ctx, + ret, + NULL, + NULL, + 0); + free(cwd); + return smb_fname; } static int vfs_gluster_ntimes(struct vfs_handle_struct *handle, -- cgit v1.2.1