summaryrefslogtreecommitdiff
path: root/source3/locking/leases_util.c
Commit message (Collapse)AuthorAgeFilesLines
* smbd: Let fsp_lease_type() look at leases.tdbVolker Lendecke2019-09-171-5/+21
| | | | | | | | | | | | The same lease can be used via different TCP connections (yes, we have tests for this!). At the end of downgrade_lease() we update all fsp's with fsps_lease_update() that link to the lease that just was changed. However, this is only in the local process, this is not cross-smbd. So other smbds using the same lease can use stale information and for example get the mandatory locking wrong. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Make lease_type_is_exclusive() staticVolker Lendecke2019-09-171-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Move fsp_client_guid() to locking/Volker Lendecke2019-08-061-0/+6
| | | | | | | | Yes, this adds another peek from locking/ back into smbd/proto.h, but locking/locking.c does the same already. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3/locking: helper functions for lease typesRalph Boehme2017-05-061-0/+17
| | | | | | | | | | Add some helper functions that will be used to update a bunch of checks for exclusive oplocks to the lease area. Bug: https://bugzilla.samba.org/show_bug.cgi?id=12766 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3/locking: add const to fsp_lease_typeRalph Boehme2017-05-061-1/+1
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=12766 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3: locking: Move two leases functions into a new file.Jeremy Allison2017-03-151-0/+55
map_oplock_to_lease_type(), fsp_lease_type(). BUG: https://bugzilla.samba.org/show_bug.cgi?id=12628 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>