Move the assert under the protection of the in_transaction flag.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
This commit is contained in:
Ewan Mellor committed 2006-11-29 12:15:45 +00:00
1 parent 26c7d28635
commit dcf51b3413
1 file changed
+2 -1
+2 -1
View File
@@ -11,11 +11,12 @@ from xen.xend.xenstore.xsutil import xshandle
class xstransact:
def __init__(self, path = ""):
assert path is not None
self.in_transaction = False # Set this temporarily -- if this
# constructor fails, then we need to
# protect __del__.
assert path is not None
self.path = path.rstrip("/")
self.transaction = xshandle().transaction_start()
self.in_transaction = True
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.