From: Ralph Boehme Date: Mon, 14 Dec 2020 14:31:37 +0000 (+0100) Subject: vfs_syncops: support real dirfsps in syncops_mkdirat() X-Git-Tag: samba-4.14.0rc1~204 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2d57908f139b0a13a2f70906ab4dcdb220d80284;p=thirdparty%2Fsamba.git vfs_syncops: support real dirfsps in syncops_mkdirat() Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison --- diff --git a/source3/modules/vfs_syncops.c b/source3/modules/vfs_syncops.c index e0dc524bb09..6fb05e52e30 100644 --- a/source3/modules/vfs_syncops.c +++ b/source3/modules/vfs_syncops.c @@ -265,12 +265,24 @@ static int syncops_mkdirat(vfs_handle_struct *handle, const struct smb_filename *smb_fname, mode_t mode) { + struct smb_filename *full_fname = NULL; + + full_fname = full_path_from_dirfsp_atname(talloc_tos(), + dirfsp, + smb_fname); + if (full_fname == NULL) { + errno = ENOMEM; + return -1; + } + SYNCOPS_NEXT_SMB_FNAME(MKDIRAT, - smb_fname, + full_fname, (handle, dirfsp, smb_fname, mode)); + + TALLOC_FREE(full_fname); } /* close needs to be handled specially */