diff options
author | Jeremy Allison <jra@samba.org> | 2011-12-16 12:26:45 -0800 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2011-12-16 23:32:26 +0100 |
commit | a6854f2c0aa5f7b4bd243f7df2ca86fb15deebe6 (patch) | |
tree | 2b29e366a989dfa0c16db852033de036dc96d0c9 /source3/smbd | |
parent | 7dcef878cdf962b4dd9715dc92ffc51284bf168f (diff) | |
download | samba-a6854f2c0aa5f7b4bd243f7df2ca86fb15deebe6.tar.gz samba-a6854f2c0aa5f7b4bd243f7df2ca86fb15deebe6.tar.bz2 samba-a6854f2c0aa5f7b4bd243f7df2ca86fb15deebe6.zip |
Fix bug #8664 - Renaming a symlink fails if the symlink target is outside of the share.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Dec 16 23:32:26 CET 2011 on sn-devel-104
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/reply.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c index d9b7500707..257ce7001a 100644 --- a/source3/smbd/reply.c +++ b/source3/smbd/reply.c @@ -6649,6 +6649,8 @@ void reply_mv(struct smb_request *req) TALLOC_CTX *ctx = talloc_tos(); struct smb_filename *smb_fname_src = NULL; struct smb_filename *smb_fname_dst = NULL; + uint32_t src_ucf_flags = lp_posix_pathnames() ? UCF_UNIX_NAME_LOOKUP : UCF_COND_ALLOW_WCARD_LCOMP; + uint32_t dst_ucf_flags = UCF_SAVE_LCOMP | (lp_posix_pathnames() ? 0 : UCF_COND_ALLOW_WCARD_LCOMP); bool stream_rename = false; START_PROFILE(SMBmv); @@ -6691,7 +6693,7 @@ void reply_mv(struct smb_request *req) conn, req->flags2 & FLAGS2_DFS_PATHNAMES, name, - UCF_COND_ALLOW_WCARD_LCOMP, + src_ucf_flags, &src_has_wcard, &smb_fname_src); @@ -6709,7 +6711,7 @@ void reply_mv(struct smb_request *req) conn, req->flags2 & FLAGS2_DFS_PATHNAMES, newname, - UCF_COND_ALLOW_WCARD_LCOMP | UCF_SAVE_LCOMP, + dst_ucf_flags, &dest_has_wcard, &smb_fname_dst); |