mirror of
https://github.com/samba-team/samba.git
synced 2025-08-03 04:22:09 +03:00
s3:smbd: give the correct error when trying to replace a stream
metze
This commit is contained in:
committed by
Jeremy Allison
parent
0b169748ce
commit
e6a2ce970b
@ -5496,6 +5496,12 @@ NTSTATUS rename_internals_fsp(connection_struct *conn,
|
||||
return NT_STATUS_OBJECT_NAME_COLLISION;
|
||||
}
|
||||
|
||||
if(replace_if_exists && dst_exists) {
|
||||
if (is_ntfs_stream_name(newname)) {
|
||||
return NT_STATUS_INVALID_PARAMETER;
|
||||
}
|
||||
}
|
||||
|
||||
if (dst_exists) {
|
||||
struct file_id fileid = vfs_file_id_from_sbuf(conn, &sbuf1);
|
||||
files_struct *dst_fsp = file_find_di_first(fileid);
|
||||
|
Reference in New Issue
Block a user