summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2010-06-01 16:45:51 +0200
committerMichael Adam <obnox@samba.org>2010-08-14 02:10:43 +0200
commit6a70e7da58c61ada84e4fbe43d6631f359a466e4 (patch)
tree432948ecca7c271ed28dfbbddd771ffd57689b15
parentd5c3cb5a8a55e325a84d5fc5f704af86588b2027 (diff)
downloadsamba-6a70e7da58c61ada84e4fbe43d6631f359a466e4.tar.gz
samba-6a70e7da58c61ada84e4fbe43d6631f359a466e4.tar.bz2
samba-6a70e7da58c61ada84e4fbe43d6631f359a466e4.zip
s3:idmap_tdb2: honour the "idmap read only" flag in the tdb2 module.
Note that this will not prevent the idmap script from writing its mappings to the database, but no new unix ids will be allocated via the allocator and hence no new mappings will be autogenerated.
-rw-r--r--source3/winbindd/idmap_tdb2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/winbindd/idmap_tdb2.c b/source3/winbindd/idmap_tdb2.c
index 0c9488ae03..e6416f1eee 100644
--- a/source3/winbindd/idmap_tdb2.c
+++ b/source3/winbindd/idmap_tdb2.c
@@ -852,7 +852,7 @@ static NTSTATUS idmap_tdb2_sids_to_unixids(struct idmap_domain *dom, struct id_m
ret = idmap_tdb2_sids_to_unixids_action(idmap_tdb2, &state);
- if (NT_STATUS_EQUAL(ret, STATUS_SOME_UNMAPPED)) {
+ if (NT_STATUS_EQUAL(ret, STATUS_SOME_UNMAPPED) && !dom->read_only) {
state.allocate_unmapped = true;
ret = dbwrap_trans_do(idmap_tdb2,
idmap_tdb2_sids_to_unixids_action,