smbd: Decouple grant_fsp_oplock_type from oplock validation
authorVolker Lendecke <vl@samba.org>
Tue, 3 Sep 2013 09:02:12 +0000 (09:02 +0000)
committerMichael Adam <obnox@samba.org>
Tue, 15 Oct 2013 22:45:43 +0000 (00:45 +0200)
commit4263d16f134bd93813a880ccb81503bc998a98f3
treee70491a9eab1f6cbbcb4d488b034b6c611cece82
parent00d84ad1928a07bc892e8a37d53e7c35b8628b7f
smbd: Decouple grant_fsp_oplock_type from oplock validation

This makes grant_fsp_oplock_type independent from the values computed
in validate_oplock_types. It *might* make oplock calculation a bit
slower for heavily shared files, as we are walking the share mode array
twice. But we are doing so much stuff in open that I doubt the difference
is measurable. It clears up the code for me however, and I think that's
worth it.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
source3/smbd/open.c