diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2015-01-26 10:02:59 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2015-01-26 10:02:59 (GMT) |
commit | 3d2256f671b7ed5c769dd34b27ae597cbc69047c (patch) | |
tree | 2a2ab6ba00008118cd98cf77fe53f48d3fce8baa /Lib/asyncio | |
parent | 2596dd08949f530c97bb6a2eda506594840d9726 (diff) | |
download | cpython-3d2256f671b7ed5c769dd34b27ae597cbc69047c.zip cpython-3d2256f671b7ed5c769dd34b27ae597cbc69047c.tar.gz cpython-3d2256f671b7ed5c769dd34b27ae597cbc69047c.tar.bz2 |
Issue #23293, asyncio: Cleanup IocpProactor.close()
The special case for connect_pipe() is not more needed. connect_pipe() doesn't
use overlapped operations anymore.
Diffstat (limited to 'Lib/asyncio')
-rw-r--r-- | Lib/asyncio/windows_events.py | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/Lib/asyncio/windows_events.py b/Lib/asyncio/windows_events.py index 42c5f6e..6c7e058 100644 --- a/Lib/asyncio/windows_events.py +++ b/Lib/asyncio/windows_events.py @@ -694,12 +694,7 @@ class IocpProactor: def close(self): # Cancel remaining registered operations. for address, (fut, ov, obj, callback) in list(self._cache.items()): - if obj is None: - # The operation was started with connect_pipe() which - # queues a task to Windows' thread pool. This cannot - # be cancelled, so just forget it. - del self._cache[address] - elif fut.cancelled(): + if fut.cancelled(): # Nothing to do with cancelled futures pass elif isinstance(fut, _WaitCancelFuture): |