]> granicus.if.org Git - python/commitdiff
- plug a memory leak due to circular lists
authorNeil Schemenauer <nascheme@enme.ucalgary.ca>
Fri, 22 Sep 2000 15:30:16 +0000 (15:30 +0000)
committerNeil Schemenauer <nascheme@enme.ucalgary.ca>
Fri, 22 Sep 2000 15:30:16 +0000 (15:30 +0000)
Lib/test/test_pickle.py

index ff9c4673bd697a7537ef46a8ed5adccc5cf16f2e..3c81fdd0841b527d509b2aadab3bfaa0a272362c 100644 (file)
@@ -80,6 +80,9 @@ def dotest(pickle):
     x2 = pickle.loads(s)
     if x2 == r: print "ok"
     else: print "bad"
+    # don't create cyclic garbage
+    del x2[0]
+    del r[0]
 
     # Test protection against closed files
     import tempfile, os