fix rename in modify

when renaming an entry, dn must be reset to the correct value for
the modifications that come after the rename.
This commit is contained in:
kakwa 2015-07-28 23:38:29 +02:00
parent f2c1a6af44
commit 9ec7a3dfbe
1 changed files with 3 additions and 0 deletions

View File

@ -311,6 +311,9 @@ class Backend(ldapcherry.backend.Backend):
dn,
ldap.dn.dn2str([[(battr, bcontent, 1)]])
)
dn = ldap.dn.dn2str(
[[(battr, bcontent, 1)]] + ldap.dn.str2dn(dn)[1:]
)
else:
if attr in old_attrs:
if type(old_attrs[attr]) is list: