diff options
| author | Victor Stinner <victor.stinner@gmail.com> | 2015-01-28 23:35:56 (GMT) | 
|---|---|---|
| committer | Victor Stinner <victor.stinner@gmail.com> | 2015-01-28 23:35:56 (GMT) | 
| commit | b507cbaac5921023c17068b616efdbbecbd89920 (patch) | |
| tree | aa903ce9662fe5c563b03178b239f461aa20b6dd /Lib/asyncio/sslproto.py | |
| parent | a89f5f049294c6d1782d9ec7be2d2b950c9a8619 (diff) | |
| download | cpython-b507cbaac5921023c17068b616efdbbecbd89920.zip cpython-b507cbaac5921023c17068b616efdbbecbd89920.tar.gz cpython-b507cbaac5921023c17068b616efdbbecbd89920.tar.bz2  | |
asyncio: Fix SSLProtocol.eof_received()
Wake-up the waiter if it is not done yet.
Diffstat (limited to 'Lib/asyncio/sslproto.py')
| -rw-r--r-- | Lib/asyncio/sslproto.py | 4 | 
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/asyncio/sslproto.py b/Lib/asyncio/sslproto.py index f2b856c..26937c8 100644 --- a/Lib/asyncio/sslproto.py +++ b/Lib/asyncio/sslproto.py @@ -489,6 +489,10 @@ class SSLProtocol(protocols.Protocol):          try:              if self._loop.get_debug():                  logger.debug("%r received EOF", self) + +            if self._waiter is not None and not self._waiter.done(): +                self._waiter.set_exception(ConnectionResetError()) +              if not self._in_handshake:                  keep_open = self._app_protocol.eof_received()                  if keep_open:  | 
