Skip to content

Commit

Permalink
send a flush value
Browse files Browse the repository at this point in the history
not setting it in client_options could result in the previous value being used
  • Loading branch information
totaam committed Nov 10, 2023
1 parent a09f80b commit ff36bc1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
3 changes: 1 addition & 2 deletions xpra/server/window/window_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -2723,8 +2723,7 @@ def nodata(msg, *args) -> None:
if mod:
client_options["encoder"] = mod
#actual network packet:
if flush not in (None, 0):
client_options["flush"] = flush
client_options["flush"] = flush or 0
if self.send_timetamps:
client_options["ts"] = image.get_timestamp()
end = monotonic()
Expand Down
7 changes: 2 additions & 5 deletions xpra/server/window/window_video_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -2122,9 +2122,7 @@ def encode_scrolling(self, scroll_data, image : ImageWrapper, options, match_pct
#send the scrolls if we have any
#(zero change scrolls have been removed - so maybe there are none)
if scrolls:
client_options = {}
if flush>0:
client_options["flush"] = flush
client_options = {"flush" : flush}
coding = "scroll"
end = monotonic()
packet = self.make_draw_packet(x, y, w, h,
Expand Down Expand Up @@ -2164,8 +2162,7 @@ def encode_scrolling(self, scroll_data, image : ImageWrapper, options, match_pct
if not data:
raise RuntimeError(f"no data from {encoding} function {encode_fn}")
flush -= 1
if flush>0:
client_options["flush"] = flush
client_options["flush"] = flush
#if SAVE_TO_FILE:
# #hard-coded for BGRA!
# from xpra.os_util import memoryview_to_bytes
Expand Down

0 comments on commit ff36bc1

Please sign in to comment.