]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: pass lease and oplock_request to open_directory()
authorRalph Boehme <slow@samba.org>
Tue, 3 Sep 2024 18:24:22 +0000 (20:24 +0200)
committerRalph Boehme <slow@samba.org>
Tue, 5 Nov 2024 14:39:30 +0000 (14:39 +0000)
Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source3/smbd/open.c

index 523820fbae3e7a9ae9f995354a112ae014fc23d2..ddce4fa58b50f6088869482264d459d739074945 100644 (file)
@@ -5148,6 +5148,8 @@ static NTSTATUS open_directory(connection_struct *conn,
                               uint32_t file_attributes,
                               struct smb_filename *parent_dir_fname,
                               struct smb_filename *smb_fname_atname,
+                              uint32_t oplock_request,
+                              const struct smb2_lease *lease,
                               struct security_descriptor *sd,
                               int *pinfo,
                               struct files_struct *fsp)
@@ -6775,7 +6777,6 @@ static NTSTATUS create_file_unixpath(connection_struct *conn,
                 * CreateDirectory() call.
                 */
 
-               oplock_request = 0;
                status = open_directory(conn,
                                        req,
                                        access_mask,
@@ -6785,6 +6786,8 @@ static NTSTATUS create_file_unixpath(connection_struct *conn,
                                        file_attributes,
                                        dirfsp->fsp_name,
                                        smb_fname_atname,
+                                       oplock_request,
+                                       lease,
                                        sd,
                                        &info,
                                        fsp);
@@ -6832,7 +6835,6 @@ static NTSTATUS create_file_unixpath(connection_struct *conn,
                                goto fail;
                        }
 
-                       oplock_request = 0;
                        status = open_directory(conn,
                                                req,
                                                access_mask,
@@ -6842,6 +6844,8 @@ static NTSTATUS create_file_unixpath(connection_struct *conn,
                                                file_attributes,
                                                dirfsp->fsp_name,
                                                smb_fname_atname,
+                                               oplock_request,
+                                               lease,
                                                sd,
                                                &info,
                                                fsp);