summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1996-11-27 19:39:58 (GMT)
committerGuido van Rossum <guido@python.org>1996-11-27 19:39:58 (GMT)
commit29e77816f5420824545cecdfc4541c91c5225ba7 (patch)
tree9bbaa91eab3a07f7fd81c2f303b9eb432749f837
parentbec74843de052a3d0d51e44173e026ef9800914f (diff)
downloadcpython-29e77816f5420824545cecdfc4541c91c5225ba7.zip
cpython-29e77816f5420824545cecdfc4541c91c5225ba7.tar.gz
cpython-29e77816f5420824545cecdfc4541c91c5225ba7.tar.bz2
Added safeguard against failure in __del__.
-rw-r--r--Lib/urllib.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/urllib.py b/Lib/urllib.py
index 2583089..4f455f8 100644
--- a/Lib/urllib.py
+++ b/Lib/urllib.py
@@ -70,6 +70,8 @@ def urlcleanup():
ftpcache = {}
class URLopener:
+ tempcache = None # So close() in __del__() won't fail
+
# Constructor
def __init__(self, proxies=None):
if proxies is None: