xpra icon
Bug tracker and wiki

This bug tracker and wiki are being discontinued
please use https://github.com/Xpra-org/xpra instead.

Opened 10 years ago

Closed 10 years ago

Last modified 8 months ago

#4 closed defect (duplicate)

windows stay visible on the screen even if the server is killed

Reported by: Timo Juhani Lindfors Owned by: Antoine Martin
Priority: major Milestone: 0.0.7.x
Component: client Version:
Keywords: Cc:


Currently if the server is killed the _to_server thread exits and
closes both _client_conn and _server_conn. However, this does not
cause the _to_client thread to stop. As a result an extra "xpra"
process stays listed in the process list and users don't notice that
the server has died. Only if you try to interactive with any of the
windows will the proxy write something to the server socket and notice
the problem.

This patch stops _to_client thread when _to_server thread exits and
vice versa. Calling _Thread_stop() is bit ugly but the alternative
would probably be to use some sort of polling mechanism instead of
blocking read() in _copy_loop.

Change History (5)

comment:1 Changed 10 years ago by Timo Juhani Lindfors

Sorry, I accidentally created two bugs when I only wanted one. Please close this and look at bug #5 instead.

comment:2 Changed 10 years ago by Timo Juhani Lindfors

If you click a window when the server has died you get

 Exception in thread Thread-2:
 Traceback (most recent call last):
   File "/usr/lib/python2.6/threading.py", line 532, in __bootstrap_inner
   File "/usr/lib/python2.6/threading.py", line 484, in run
      self.__target(*self.__args, **self.__kwargs)
   File "/usr/lib/python2.6/dist-packages/xpra/proxy.py", line 28, in _to_server_loop
     self._copy_loop("->server", self._client_conn, self._server_conn)
    File "/usr/lib/python2.6/dist-packages/xpra/proxy.py", line 40, in _copy_loop
     buf = buf[to_conn.write(buf):]
   File "/usr/lib/python2.6/dist-packages/xpra/protocol.py", line 50, in write
     return self._s.send(buf)
   File "/usr/lib/python2.6/socket.py", line 167, in _dummy
      raise error(EBADF, 'Bad file descriptor')
 error: [Errno 9] Bad file descriptor
 Connection lost
 Error reading from connection: I/O operation on closed file

After this patch you get

Connection lost

immediately when the server dies

comment:3 Changed 10 years ago by Antoine Martin

Resolution: duplicate
Status: newclosed

Dupe of #5 (more details and patch there)

comment:4 Changed 10 years ago by Antoine Martin

Milestone: 0.0.7.x

comment:5 Changed 8 months ago by migration script

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/4

Note: See TracTickets for help on using tickets.