From 7ae1fdcbb2f44210f1be3dabd7afc07b9b989b64 Mon Sep 17 00:00:00 2001 From: Ralph Boehme Date: Tue, 17 May 2022 15:25:35 +0200 Subject: vfs_gpfs: pass fsp to gpfs_get_nfs4_acl() BUG: https://bugzilla.samba.org/show_bug.cgi?id=15069 Signed-off-by: Ralph Boehme Reviewed-by: Christof Schmitt (cherry picked from commit 5f4625a2859bf622ea2034e5bbf63f9959e58b78) --- source3/modules/vfs_gpfs.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/source3/modules/vfs_gpfs.c b/source3/modules/vfs_gpfs.c index a7029e877da..b607578b354 100644 --- a/source3/modules/vfs_gpfs.c +++ b/source3/modules/vfs_gpfs.c @@ -523,9 +523,11 @@ again: * On failure returns -1 if there is system (GPFS) error, check errno. * Returns 0 on success */ -static int gpfs_get_nfs4_acl(TALLOC_CTX *mem_ctx, const char *fname, +static int gpfs_get_nfs4_acl(TALLOC_CTX *mem_ctx, + struct files_struct *fsp, struct SMB4ACL_T **ppacl) { + const char *fname = fsp->fsp_name->base_name; gpfs_aclCount_t i; struct gpfs_acl *gacl = NULL; DEBUG(10, ("gpfs_get_nfs4_acl invoked for %s\n", fname)); @@ -644,7 +646,7 @@ static NTSTATUS gpfsacl_fget_nt_acl(vfs_handle_struct *handle, return status; } - result = gpfs_get_nfs4_acl(frame, fsp->fsp_name->base_name, &pacl); + result = gpfs_get_nfs4_acl(frame, fsp, &pacl); if (result == 0) { status = smb_fget_nt_acl_nfs4(fsp, &config->nfs4_params, @@ -1272,7 +1274,7 @@ static int gpfsacl_emu_chmod(vfs_handle_struct *handle, DEBUG(10, ("gpfsacl_emu_chmod invoked for %s mode %o\n", path, mode)); - result = gpfs_get_nfs4_acl(frame, path, &pacl); + result = gpfs_get_nfs4_acl(frame, fsp, &pacl); if (result) { TALLOC_FREE(frame); return result; -- cgit v1.2.1