From: Jeremy Allison Date: Thu, 15 Dec 2011 23:50:23 +0000 (-0800) Subject: First part of fix for bug #8663 - deleting a symlink fails if the symlink target... X-Git-Tag: samba-3.5.13~13 X-Git-Url: http://git.samba.org/samba.git/?p=ira%2Ftdb.git;a=commitdiff_plain;h=f0f9d4b407ed26d44043ead5644982c26e0edf10 First part of fix for bug #8663 - deleting a symlink fails if the symlink target is outside of the share. Remove two unneeded check_name() calls. They have already been done in order to get here. (cherry picked from commit 4ceba7f93f530302f3edb23be4e44e3366bcc768) --- diff --git a/source3/smbd/open.c b/source3/smbd/open.c index 70e6b4f56ec..693e488a4bc 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -1431,11 +1431,6 @@ static NTSTATUS open_file_ntcreate(connection_struct *conn, remove_deferred_open_smb_message(req->mid); } - status = check_name(conn, smb_fname->base_name); - if (!NT_STATUS_IS_OK(status)) { - return status; - } - if (!posix_open) { new_dos_attributes &= SAMBA_ATTRIBUTES_MASK; if (file_existed) { @@ -3308,13 +3303,6 @@ NTSTATUS create_file_default(connection_struct *conn, } } - /* All file access must go through check_name() */ - - status = check_name(conn, smb_fname->base_name); - if (!NT_STATUS_IS_OK(status)) { - goto fail; - } - status = create_file_unixpath( conn, req, smb_fname, access_mask, share_access, create_disposition, create_options, file_attributes,