File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -681,14 +681,14 @@ cdef class UVStream(UVBaseTransport):
681
681
self ._conn_lost += 1
682
682
return
683
683
684
- cdef ssize_t written
684
+ cdef ssize_t bytes_written
685
685
686
686
if (not self ._protocol_paused and self ._buffer_size == 0 and
687
687
(< uv.uv_stream_t* > self ._handle).write_queue_size == 0 ):
688
688
689
- written_ = self ._try_write(buf)
689
+ bytes_written_ = self ._try_write(buf)
690
690
691
- if written_ is None :
691
+ if bytes_written_ is None :
692
692
# A `self._fatal_error` was called.
693
693
# It might not raise an exception under some
694
694
# conditions.
@@ -698,24 +698,24 @@ cdef class UVStream(UVBaseTransport):
698
698
699
699
return
700
700
701
- written = written_
701
+ bytes_written = bytes_written_
702
702
703
- if written == 0 :
704
- # All data was successfully written .
703
+ if bytes_written == 0 :
704
+ # All data was successfully bytes_written .
705
705
# on_write will call "maybe_resume_protocol".
706
706
return
707
707
708
- if written > 0 :
708
+ if bytes_written > 0 :
709
709
if UVLOOP_DEBUG:
710
- if written == len (buf):
710
+ if bytes_written == len (buf):
711
711
raise RuntimeError (' _try_write sent all data and '
712
712
' returned non-zero' )
713
713
714
714
if PyBytes_CheckExact(buf):
715
715
# Cast bytes to memoryview to avoid copying
716
716
# data that wasn't sent.
717
717
buf = memoryview(buf)
718
- buf = buf[written_ :]
718
+ buf = buf[bytes_written_ :]
719
719
720
720
# At this point it's either data was sent partially,
721
721
# or an EAGAIN has happened.
You can’t perform that action at this time.
0 commit comments