gh-108903: Remove unneeded lambdas from asyncio (GH-108904)

This commit is contained in:
Nikita Sobolev 2023-09-05 18:11:12 +03:00 committed by GitHub
parent 1e0d62793a
commit ad1d6a1c20
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View file

@ -539,7 +539,7 @@ class SSLProtocol(protocols.BufferedProtocol):
# start handshake timeout count down
self._handshake_timeout_handle = \
self._loop.call_later(self._ssl_handshake_timeout,
lambda: self._check_handshake_timeout())
self._check_handshake_timeout)
self._do_handshake()
@ -619,7 +619,7 @@ class SSLProtocol(protocols.BufferedProtocol):
self._set_state(SSLProtocolState.FLUSHING)
self._shutdown_timeout_handle = self._loop.call_later(
self._ssl_shutdown_timeout,
lambda: self._check_shutdown_timeout()
self._check_shutdown_timeout
)
self._do_flush()
@ -758,7 +758,7 @@ class SSLProtocol(protocols.BufferedProtocol):
else:
break
else:
self._loop.call_soon(lambda: self._do_read())
self._loop.call_soon(self._do_read)
except SSLAgainErrors:
pass
if offset > 0: