From 0d3995cec10c5fae8c8b6a1df312062e38437e6f Mon Sep 17 00:00:00 2001 From: Ralph Boehme Date: Wed, 27 Jul 2022 16:04:24 +0200 Subject: [PATCH] smdb: use fsp_is_alternate_stream() in open_file() No change in behaviour. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15126 MR: https://gitlab.com/samba-team/samba/-/merge_requests/2643 Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke --- source3/smbd/open.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source3/smbd/open.c b/source3/smbd/open.c index f1c2f7382bc..45b1abb1124 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -1406,7 +1406,7 @@ static NTSTATUS open_file(struct smb_request *req, #endif /* Don't create files with Microsoft wildcard characters. */ - if (fsp->base_fsp) { + if (fsp_is_alternate_stream(fsp)) { /* * wildcard characters are allowed in stream names * only test the basefilename @@ -1422,7 +1422,7 @@ static NTSTATUS open_file(struct smb_request *req, } /* Can we access this file ? */ - if (!fsp->base_fsp) { + if (!fsp_is_alternate_stream(fsp)) { /* Only do this check on non-stream open. */ if (file_existed) { status = smbd_check_access_rights_fsp( -- 2.47.3