Changeset 2559

Show
Ignore:
Timestamp:
08/10/07 03:34:50 (1 year ago)
Author:
roadrunner
Message:

XsltMacro:

del is called even if init raises an exception, but in this case
self.obj will be null, so check for that.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • xsltmacro/0.9/xslt/Xslt.py

    r2312 r2559  
    340340 
    341341    def __del__(self): 
    342         if hasattr(self.obj, 'close') and callable(self.obj.close): 
     342        if self.obj and hasattr(self.obj, 'close') and callable(self.obj.close): 
    343343            self.obj.close() 
    344344