mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
asyncio: SSL transports now clear their reference to the waiter
* Rephrase also the comment explaining why the waiter is not awaken immediatly. * SSLProtocol.eof_received() doesn't instanciate ConnectionResetError exception directly, it will be done by Future.set_exception(). The exception is not used if the waiter was cancelled or if there is no waiter.
This commit is contained in:
parent
b507cbaac5
commit
f07801bb17
4 changed files with 32 additions and 21 deletions
|
@ -38,7 +38,7 @@ class _ProactorBasePipeTransport(transports._FlowControlMixin,
|
|||
self._server._attach()
|
||||
self._loop.call_soon(self._protocol.connection_made, self)
|
||||
if waiter is not None:
|
||||
# wait until protocol.connection_made() has been called
|
||||
# only wake up the waiter when connection_made() has been called
|
||||
self._loop.call_soon(waiter._set_result_unless_cancelled, None)
|
||||
|
||||
def __repr__(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue