summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbtimby <btimby@67cdc799-7952-0410-af00-57a81ceafa0f>2012-11-15 21:24:43 +0000
committerbtimby <btimby@67cdc799-7952-0410-af00-57a81ceafa0f>2012-11-15 21:24:43 +0000
commitb68ace7ec73ee31d7c5ff22cf95e38904ee26c67 (patch)
tree1415d12ae66c200a85cfcf441126444b6e3ab379
parent31859519763229d5e83a3e5942b64ae7dc801f0e (diff)
downloadpyfilesystem-b68ace7ec73ee31d7c5ff22cf95e38904ee26c67.tar.gz
If the wrapped_fs reference is not removed, the SubFS will create a cycle with it, preventing both from being garbage collected.
git-svn-id: http://pyfilesystem.googlecode.com/svn/trunk@827 67cdc799-7952-0410-af00-57a81ceafa0f
-rw-r--r--fs/wrapfs/__init__.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/wrapfs/__init__.py b/fs/wrapfs/__init__.py
index 7b9d1af..df89f5b 100644
--- a/fs/wrapfs/__init__.py
+++ b/fs/wrapfs/__init__.py
@@ -432,6 +432,7 @@ class WrapFS(FS):
if not self.closed:
self.wrapped_fs.close()
super(WrapFS,self).close()
+ self.wrapped_fs = None
def wrap_fs_methods(decorator, cls=None, exclude=[]):