Initialize self.__tempfiles to [] in the constructor (else it remains

a shared class variable -- but each instance will attempt to clean it
up entirely ob cleanup).
This commit is contained in:
Guido van Rossum 1997-09-08 02:16:33 +00:00
parent 62b297b698
commit 10499324cf
1 changed files with 1 additions and 0 deletions

View File

@ -91,6 +91,7 @@ class URLopener:
self.proxies = proxies
server_version = "Python-urllib/%s" % __version__
self.addheaders = [('User-agent', server_version)]
self.__tempfiles = []
self.tempcache = None
# Undocumented feature: if you assign {} to tempcache,
# it is used to cache files retrieved with