summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2011-02-04 11:05:40 +1100
committerAndrew Tridgell <tridge@samba.org>2011-02-07 13:22:01 +1100
commit5d15f28fc11412ef736ff30c401fe034c7b34115 (patch)
tree0630792776892fe6817d7688ad2b90838e75cc91
parentf4a1b71b2b6f2fa87581832a6638b88829b539b1 (diff)
downloadsamba-5d15f28fc11412ef736ff30c401fe034c7b34115.tar.gz
samba-5d15f28fc11412ef736ff30c401fe034c7b34115.tar.bz2
samba-5d15f28fc11412ef736ff30c401fe034c7b34115.zip
s4-upgradeprovision: renames need a relax to avoid subtree_rename checks
-rwxr-xr-xsource4/scripting/python/samba/upgradehelpers.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/source4/scripting/python/samba/upgradehelpers.py b/source4/scripting/python/samba/upgradehelpers.py
index a10c6d39da..5bd341cedc 100755
--- a/source4/scripting/python/samba/upgradehelpers.py
+++ b/source4/scripting/python/samba/upgradehelpers.py
@@ -421,8 +421,9 @@ def identic_rename(ldbobj, dn):
:param dn: DN of the object to manipulate
"""
(before, after) = str(dn).split('=', 1)
- ldbobj.rename(dn, ldb.Dn(ldbobj, "%s=foo%s" % (before, after)))
- ldbobj.rename(ldb.Dn(ldbobj, "%s=foo%s" % (before, after)), dn)
+ # we need to use relax to avoid the subtree_rename constraints
+ ldbobj.rename(dn, ldb.Dn(ldbobj, "%s=foo%s" % (before, after)), ["relax:0"])
+ ldbobj.rename(ldb.Dn(ldbobj, "%s=foo%s" % (before, after)), dn, ["relax:0"])
def chunck_acl(acl):