From: Jeremy Allison Date: Thu, 26 Mar 2020 01:41:10 +0000 (-0700) Subject: s3: smbd: Add 'const char *dst_original_lcomp' parameter to rename_internals() X-Git-Tag: ldb-2.2.0~1152 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6c6e5d52ea31f6ddc81823603573c4e3f1a6e93c;p=thirdparty%2Fsamba.git s3: smbd: Add 'const char *dst_original_lcomp' parameter to rename_internals() Pass through the existing smb_fname_dst->original_lcomp parameter so no logic change. Preparing to remove the use of original_lcomp. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/smbd/nttrans.c b/source3/smbd/nttrans.c index 9f8fa7f47f1..229232244c4 100644 --- a/source3/smbd/nttrans.c +++ b/source3/smbd/nttrans.c @@ -1707,6 +1707,7 @@ void reply_ntrename(struct smb_request *req) req, smb_fname_old, smb_fname_new, + smb_fname_new->original_lcomp, attrs, false, src_has_wcard, diff --git a/source3/smbd/proto.h b/source3/smbd/proto.h index d6d85e12a61..cb32ebaca5e 100644 --- a/source3/smbd/proto.h +++ b/source3/smbd/proto.h @@ -1026,6 +1026,7 @@ NTSTATUS rename_internals(TALLOC_CTX *ctx, struct smb_request *req, struct smb_filename *smb_fname_src, struct smb_filename *smb_fname_dst, + const char *dst_original_lcomp, uint32_t attrs, bool replace_if_exists, bool src_has_wild, diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c index 31ef904d65b..369398116a4 100644 --- a/source3/smbd/reply.c +++ b/source3/smbd/reply.c @@ -7900,6 +7900,7 @@ NTSTATUS rename_internals(TALLOC_CTX *ctx, struct smb_request *req, struct smb_filename *smb_fname_src, struct smb_filename *smb_fname_dst, + const char *dst_original_lcomp, uint32_t attrs, bool replace_if_exists, bool src_has_wild, @@ -7998,7 +7999,7 @@ NTSTATUS rename_internals(TALLOC_CTX *ctx, conn->short_case_preserve, smb_fname_str_dbg(smb_fname_src), smb_fname_str_dbg(smb_fname_dst), - smb_fname_dst->original_lcomp)); + dst_original_lcomp)); /* The dest name still may have wildcards. */ if (dest_has_wild) { @@ -8065,7 +8066,7 @@ NTSTATUS rename_internals(TALLOC_CTX *ctx, status = rename_internals_fsp(conn, fsp, smb_fname_dst, - smb_fname_dst->original_lcomp, + dst_original_lcomp, attrs, replace_if_exists); @@ -8393,6 +8394,7 @@ void reply_mv(struct smb_request *req) req, smb_fname_src, smb_fname_dst, + smb_fname_dst->original_lcomp, attrs, false, src_has_wcard, diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 70d45bf7654..bbb894c1af3 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -7463,6 +7463,7 @@ static NTSTATUS smb_file_rename_information(connection_struct *conn, req, smb_fname_src, smb_fname_dst, + smb_fname_dst->original_lcomp, 0, overwrite, false,