1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-16 00:23:52 +03:00

python:upgrade/upgradeprovision: use dn.copy to align ldbs

We need to do this when the dn is on a message from another ldb.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Douglas Bagnall
2024-03-17 18:07:44 +13:00
committed by Andrew Bartlett
parent 345eb854c3
commit d38a9e93cf
3 changed files with 8 additions and 8 deletions

View File

@@ -178,7 +178,7 @@ def add_idmap_entry(idmapdb, sid, xid, xid_type, logger):
if found:
try:
m = ldb.Message()
m.dn = msg[0]['dn']
m.dn = msg[0]['dn'].copy(m.ldb)
m['xidNumber'] = ldb.MessageElement(
str(xid), ldb.FLAG_MOD_REPLACE, 'xidNumber')
m['type'] = ldb.MessageElement(