Merge 2.2

This commit is contained in:
grossmj
2023-01-05 12:38:00 +08:00
21 changed files with 301 additions and 50 deletions

View File

@ -200,6 +200,7 @@ class AsyncioTelnetServer:
except ConnectionError:
async with self._lock:
network_writer.close()
await network_writer.wait_closed()
if self._reader_process == network_reader:
self._reader_process = None
# Cancel current read from this reader
@ -214,6 +215,8 @@ class AsyncioTelnetServer:
try:
writer.write_eof()
await writer.drain()
writer.close()
await writer.wait_closed()
except (AttributeError, ConnectionError):
continue