s3: Remove the unused "file_existed" parameter from smbd_calculate_access_mask
authorVolker Lendecke <vl@samba.org>
Fri, 16 Dec 2011 17:56:40 +0000 (18:56 +0100)
committerVolker Lendecke <vlendec@samba.org>
Tue, 3 Jan 2012 14:16:49 +0000 (15:16 +0100)
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Tue Jan  3 15:16:50 CET 2012 on sn-devel-104

source3/smbd/fake_file.c
source3/smbd/globals.h
source3/smbd/open.c
source3/smbd/smb2_create.c

index 2b31ba5ae038cc53a9cc54d8a13251f4e3803eef..95f6f932d930b278917a25eff38240532369c447 100644 (file)
@@ -130,7 +130,6 @@ NTSTATUS open_fake_file(struct smb_request *req, connection_struct *conn,
        NTSTATUS status;
 
        status = smbd_calculate_access_mask(conn, smb_fname,
-                                           false, /* fake files do not exist */
                                            access_mask, &access_mask);
        if (!NT_STATUS_IS_OK(status)) {
                DEBUG(10, ("open_fake_file: smbd_calculate_access_mask "
index 02527e74536a7143ab75e4ae6fe4445003fc5b75..631298b15598ef76d8bfa11875b9d900aeb62773 100644 (file)
@@ -214,7 +214,6 @@ bool smbd_dirptr_lanman2_entry(TALLOC_CTX *ctx,
 
 NTSTATUS smbd_calculate_access_mask(connection_struct *conn,
                                    const struct smb_filename *smb_fname,
-                                   bool file_existed,
                                    uint32_t access_mask,
                                    uint32_t *access_mask_out);
 
index d9491b5f041e8b137270f2b0d6656cf5f2460753..dbc4dba4487e58171bb96b2b436722bc25cadcc2 100644 (file)
@@ -1534,7 +1534,6 @@ static NTSTATUS smbd_calculate_maximum_allowed_access(
 
 NTSTATUS smbd_calculate_access_mask(connection_struct *conn,
                                    const struct smb_filename *smb_fname,
-                                   bool file_existed,
                                    uint32_t access_mask,
                                    uint32_t *access_mask_out)
 {
@@ -1887,7 +1886,7 @@ static NTSTATUS open_file_ntcreate(connection_struct *conn,
                }
        }
 
-       status = smbd_calculate_access_mask(conn, smb_fname, file_existed,
+       status = smbd_calculate_access_mask(conn, smb_fname,
                                        access_mask,
                                        &access_mask); 
        if (!NT_STATUS_IS_OK(status)) {
@@ -2744,7 +2743,7 @@ static NTSTATUS open_directory(connection_struct *conn,
                return NT_STATUS_NOT_A_DIRECTORY;
        }
 
-       status = smbd_calculate_access_mask(conn, smb_dname, dir_existed,
+       status = smbd_calculate_access_mask(conn, smb_dname,
                                            access_mask, &access_mask);
        if (!NT_STATUS_IS_OK(status)) {
                DEBUG(10, ("open_directory: smbd_calculate_access_mask "
index 6218592e3e7dc01231a3024adf865f627e8c530b..5f834cd1dd19c9446c475068ddb278a6936ad130 100644 (file)
@@ -745,11 +745,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 
                                status = smbd_calculate_access_mask(smb1req->conn,
                                                        result->fsp_name,
-                                                       /*
-                                                        * at this stage
-                                                        * it exists
-                                                        */
-                                                       true,
                                                        SEC_FLAG_MAXIMUM_ALLOWED,
                                                        &max_access_granted);