From: Jeremy Allison Date: Wed, 26 May 2021 19:11:36 +0000 (-0700) Subject: s3: smbd: In check_parent_access(), parent_smb_fname() -> SMB_VFS_PARENT_PATHNAME(). X-Git-Tag: tevent-0.11.0~676 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=38410ea2f7e19e0e4586d7a5c5453658edde6007;p=thirdparty%2Fsamba.git s3: smbd: In check_parent_access(), parent_smb_fname() -> SMB_VFS_PARENT_PATHNAME(). Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/smbd/open.c b/source3/smbd/open.c index 919ccf4cab8..ba8d4fbabee 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -325,7 +325,6 @@ NTSTATUS check_parent_access(struct connection_struct *conn, bool delete_on_close_set; int ret; TALLOC_CTX *frame = talloc_stackframe(); - bool ok; /* * NB. When dirfsp != conn->cwd_fsp, we must @@ -334,9 +333,12 @@ NTSTATUS check_parent_access(struct connection_struct *conn, SMB_ASSERT(dirfsp == conn->cwd_fsp); - ok = parent_smb_fname(frame, smb_fname, &parent_dir, NULL); - if (!ok) { - status = NT_STATUS_NO_MEMORY; + status = SMB_VFS_PARENT_PATHNAME(conn, + frame, + smb_fname, + &parent_dir, + NULL); + if (!NT_STATUS_IS_OK(status)) { goto out; }