mirror of
https://github.com/python/cpython.git
synced 2025-08-02 16:13:13 +00:00
iteritems() should not have been used for self.timeout which changes during the loop.
This commit is contained in:
parent
bfef18ca0e
commit
4ec4fa208e
1 changed files with 1 additions and 1 deletions
|
@ -1012,7 +1012,7 @@ class CacheFTPHandler(FTPHandler):
|
||||||
# first check for old ones
|
# first check for old ones
|
||||||
t = time.time()
|
t = time.time()
|
||||||
if self.soonest <= t:
|
if self.soonest <= t:
|
||||||
for k, v in self.timeout.iteritems():
|
for k, v in self.timeout.items():
|
||||||
if v < t:
|
if v < t:
|
||||||
self.cache[k].close()
|
self.cache[k].close()
|
||||||
del self.cache[k]
|
del self.cache[k]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue