Skip to content

Commit

Permalink
we can lose the client from another thread
Browse files Browse the repository at this point in the history
  • Loading branch information
totaam committed Nov 15, 2021
1 parent d52cef6 commit 611ab87
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion xpra/platform/darwin/shadow_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,8 @@ def stop_refresh(self, wid):


def do_process_mouse_common(self, proto, wid, pointer, *args):
assert proto in self._server_sources
if proto not in self._server_sources:
return pointer
assert wid in self._id_to_window
CG.CGWarpMouseCursorPosition(pointer[:2])
return pointer
Expand Down
9 changes: 6 additions & 3 deletions xpra/x11/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -883,7 +883,8 @@ def _restack_window(self, window, detail, sibling):


def _set_window_state(self, proto, wid, window, new_window_state):
assert proto in self._server_sources
if proto not in self._server_sources:
return []
if not new_window_state:
return []
nws = typedict(new_window_state)
Expand Down Expand Up @@ -1137,7 +1138,8 @@ def _move_pointer(self, wid, pos, *args):


def _process_close_window(self, proto, packet):
assert proto in self._server_sources
if proto not in self._server_sources:
return
wid = packet[1]
window = self._lookup_window(wid)
windowlog("client closed window %s - %s", wid, window)
Expand All @@ -1149,7 +1151,8 @@ def _process_close_window(self, proto, packet):


def _process_window_signal(self, proto, packet):
assert proto in self._server_sources
if proto not in self._server_sources:
return
wid = packet[1]
sig = bytestostr(packet[2])
if sig not in WINDOW_SIGNALS:
Expand Down

0 comments on commit 611ab87

Please sign in to comment.