Univention Bugzilla – Attachment 7778 Details for
Bug 41294
cancel() not called when creating object fails
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch
41294.patch (text/plain), 1.42 KB, created by
Florian Best
on 2016-06-30 16:46:25 CEST
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Florian Best
Created:
2016-06-30 16:46:25 CEST
Size:
1.42 KB
patch
obsolete
>diff --git a/management/univention-directory-manager-modules/modules/univention/admin/handlers/__init__.py b/management/univention-directory-manager-modules/modules/univention/admin/handlers/__init__.py >index 3535243..fffa086 100644 >--- a/management/univention-directory-manager-modules/modules/univention/admin/handlers/__init__.py >+++ b/management/univention-directory-manager-modules/modules/univention/admin/handlers/__init__.py >@@ -725,11 +725,11 @@ def _create(self): > > univention.debug.debug(univention.debug.ADMIN, univention.debug.INFO, "create object with dn: %s" % (self.dn,)) > univention.debug.debug(univention.debug.ADMIN, 99, 'Create dn=%r;\naddlist=%r;' % (self.dn, al)) >- self.lo.add(self.dn, al) >- self._exists = True > > # if anything goes wrong we need to remove the already created object, otherwise we run into 'already exists' errors > try: >+ self.lo.add(self.dn, al) >+ self._exists = True > self._ldap_post_create() > except: > # ensure that there is no lock left >@@ -741,7 +741,8 @@ def _create(self): > except: > univention.debug.debug(univention.debug.ADMIN, univention.debug.ERROR, "Post-create: cancel() failed: %s" % (traceback.format_exc(),)) > try: >- self.remove() >+ if self._exists: >+ self.remove() > except: > univention.debug.debug(univention.debug.ADMIN, univention.debug.ERROR, "Post-create: remove() failed: %s" % (traceback.format_exc(),)) > raise exc[0], exc[1], exc[2]
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 41294
:
7668
| 7778