mirror of
https://github.com/KrisKennaway/ii-vision.git
synced 2025-08-15 10:27:46 +00:00
Fix video termination logic
This commit is contained in:
@@ -79,7 +79,7 @@ class Movie:
|
|||||||
:return:
|
:return:
|
||||||
"""
|
"""
|
||||||
for op in ops:
|
for op in ops:
|
||||||
if self.stream_pos >= self.max_bytes_out:
|
if self.max_bytes_out and self.stream_pos >= self.max_bytes_out:
|
||||||
yield from self.done()
|
yield from self.done()
|
||||||
return
|
return
|
||||||
# Keep track of where we are in TCP client socket buffer
|
# Keep track of where we are in TCP client socket buffer
|
||||||
@@ -89,6 +89,8 @@ class Movie:
|
|||||||
yield from self._emit_bytes(opcodes.Ack())
|
yield from self._emit_bytes(opcodes.Ack())
|
||||||
yield from self._emit_bytes(op)
|
yield from self._emit_bytes(op)
|
||||||
|
|
||||||
|
yield from self.done()
|
||||||
|
|
||||||
def done(self) -> Iterator[int]:
|
def done(self) -> Iterator[int]:
|
||||||
"""Terminate opcode stream.
|
"""Terminate opcode stream.
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user