]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: Slightly simplify open_file_ntcreate()
authorVolker Lendecke <vl@samba.org>
Fri, 2 Aug 2019 13:24:16 +0000 (15:24 +0200)
committerJeremy Allison <jra@samba.org>
Mon, 19 Aug 2019 23:14:39 +0000 (23:14 +0000)
There is no reference to "file_existed" after this point anymore

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/open.c

index 77dd33b837871ab3847870071a41e14817112558..ea5be99bd31660f69fb2d011c2626dbb32261f18 100644 (file)
@@ -3489,18 +3489,6 @@ static NTSTATUS open_file_ntcreate(connection_struct *conn,
        status = open_mode_check(conn, lck,
                                 access_mask, share_access);
 
-       if (NT_STATUS_EQUAL(status, NT_STATUS_SHARING_VIOLATION) ||
-           (lck->data->num_share_modes > 0)) {
-               /*
-                * This comes from ancient times out of open_mode_check. I
-                * have no clue whether this is still necessary. I can't think
-                * of a case where this would actually matter further down in
-                * this function. I leave it here for further investigation
-                * :-)
-                */
-               file_existed = true;
-       }
-
        if (req != NULL) {
                /*
                 * Handle oplocks, deferring the request if delay_for_oplock()