diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2010-10-29 11:08:32 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2010-10-29 11:08:32 (GMT) |
commit | 5efe9d0865235d61f4c8c8d339a398a9adb50aca (patch) | |
tree | 7c9aab982334a422ebc47dc399429ea8c6b10680 /Lib/test/threaded_import_hangers.py | |
parent | 14d8fe7de85a99284f407ea282220b9a050ba940 (diff) | |
download | cpython-5efe9d0865235d61f4c8c8d339a398a9adb50aca.zip cpython-5efe9d0865235d61f4c8c8d339a398a9adb50aca.tar.gz cpython-5efe9d0865235d61f4c8c8d339a398a9adb50aca.tar.bz2 |
Fix ResourceWarning in Lib/test/threaded_import_hangers.py
Diffstat (limited to 'Lib/test/threaded_import_hangers.py')
-rw-r--r-- | Lib/test/threaded_import_hangers.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/threaded_import_hangers.py b/Lib/test/threaded_import_hangers.py index d750874..adf03e3 100644 --- a/Lib/test/threaded_import_hangers.py +++ b/Lib/test/threaded_import_hangers.py @@ -29,7 +29,7 @@ class Worker(threading.Thread): for name, func, args in [ # Bug 147376: TemporaryFile hung on Windows, starting in Python 2.4. - ("tempfile.TemporaryFile", tempfile.TemporaryFile, ()), + ("tempfile.TemporaryFile", lambda: tempfile.TemporaryFile().close(), ()), # The real cause for bug 147376: ntpath.abspath() caused the hang. ("os.path.abspath", os.path.abspath, ('.',)), |