dsdb: lock metadata.tdb during lock_read in partitions module
authorAndrew Bartlett <abartlet@samba.org>
Wed, 15 May 2019 22:44:42 +0000 (10:44 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 20 May 2019 04:01:10 +0000 (04:01 +0000)
commit46185daeb212267ebb0e4abe8bdad8c7cd7bfce2
tree906c7b438bad0347f3e7e5bcb2133de93fe76479
parent99867565a5070c072abcf7abc69bba9849b4984a
dsdb: lock metadata.tdb during lock_read in partitions module

metadata.tdb was being locked during transactions, but not during read, and
we should ensure we take all our locks in order for consistency

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13950

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
source4/dsdb/samdb/ldb_modules/partition.c
source4/dsdb/samdb/ldb_modules/partition.h
source4/dsdb/samdb/ldb_modules/partition_metadata.c