]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: in contend_dirleases() don't bother checking when not enabled
authorRalph Boehme <slow@samba.org>
Fri, 23 Jan 2026 10:27:28 +0000 (11:27 +0100)
committerRalph Boehme <slow@samba.org>
Mon, 26 Jan 2026 12:09:13 +0000 (12:09 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=15984

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Martin Schwenke <martins@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Mon Jan 26 12:09:13 UTC 2026 on atb-devel-224

source3/smbd/smb2_oplock.c

index 5c2a1ae848f3e892d7d1035912bb20134b6cdcc3..8f1e8540818d031e4fb1d1fa4295d0597b0770fb 100644 (file)
@@ -1316,6 +1316,10 @@ void contend_dirleases(struct connection_struct *conn,
        int ret;
        bool ok;
 
+       if (!lp_smb3_directory_leases()) {
+               return;
+       }
+
        if (lease != NULL) {
                DBG_DEBUG("Parent leasekey %"PRIx64"/%"PRIx64"\n",
                          lease->parent_lease_key.data[0],