summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Cholasta <jcholast@redhat.com>2014-01-22 12:50:19 +0100
committerPetr Viktorin <pviktori@redhat.com>2014-01-24 20:29:31 +0100
commita5f322cb7b9b4d999a6394197c3730062896780c (patch)
tree9943fdb43f572f64a678549960833a2ce3a2b43c
parente218f282a09be397f328731e0364937f903b0afd (diff)
downloadfreeipa-a5f322cb7b9b4d999a6394197c3730062896780c.zip
freeipa-a5f322cb7b9b4d999a6394197c3730062896780c.tar.gz
freeipa-a5f322cb7b9b4d999a6394197c3730062896780c.tar.xz
Get original entry state from LDAP in LDAPUpdate.
-rw-r--r--ipalib/plugins/baseldap.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/ipalib/plugins/baseldap.py b/ipalib/plugins/baseldap.py
index eab8d74..c59f5fa 100644
--- a/ipalib/plugins/baseldap.py
+++ b/ipalib/plugins/baseldap.py
@@ -1332,7 +1332,12 @@ class LDAPUpdate(LDAPQuery, crud.Update):
# mean an error occurred, just that there were no other updates to
# perform.
assert isinstance(dn, DN)
- self._exc_wrapper(keys, options, ldap.update_entry)(dn, entry_attrs)
+
+ update = self._exc_wrapper(keys, options, ldap.get_entry)(
+ dn, entry_attrs.keys())
+ update.update(entry_attrs)
+
+ self._exc_wrapper(keys, options, ldap.update_entry)(update)
except errors.EmptyModlist, e:
if not rdnupdate:
raise e