mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
asyncio, tulip issue 202: Add unit test of pause/resume writing for proactor
socket transport
This commit is contained in:
parent
049882e561
commit
df75d5b402
2 changed files with 82 additions and 4 deletions
|
@ -230,10 +230,6 @@ class _ProactorBaseWritePipeTransport(_ProactorBasePipeTransport,
|
|||
assert self._buffer is None
|
||||
# Pass a copy, except if it's already immutable.
|
||||
self._loop_writing(data=bytes(data))
|
||||
# XXX Should we pause the protocol at this point
|
||||
# if len(data) > self._high_water? (That would
|
||||
# require keeping track of the number of bytes passed
|
||||
# to a send() that hasn't finished yet.)
|
||||
elif not self._buffer: # WRITING -> BACKED UP
|
||||
# Make a mutable copy which we can extend.
|
||||
self._buffer = bytearray(data)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue