Skip to content

Commit

Permalink
#391: register the signal handlers just once to prevent osx from fall…
Browse files Browse the repository at this point in the history
…ing over itself

git-svn-id: https://xpra.org/svn/Xpra/trunk@12254 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Mar 28, 2016
1 parent 5b8ae6d commit 586b026
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
4 changes: 0 additions & 4 deletions src/xpra/scripts/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -968,10 +968,6 @@ def run_server(error_cb, opts, mode, xpra_file, extra_args, desktop_display=None
error_cb("--exit-with-children specified without any children to spawn; exiting immediately")

atexit.register(run_cleanups)
#the server class will usually override those:
#SIGINT breaks GTK3.. (but there are no py3k servers!)
signal.signal(signal.SIGINT, deadly_signal)
signal.signal(signal.SIGTERM, deadly_signal)

# Generate the script text now, because os.getcwd() will
# change if/when we daemonize:
Expand Down
3 changes: 2 additions & 1 deletion src/xpra/server/server_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,8 +356,9 @@ def get_server_mode(self):
def run(self):
self.print_run_info()
self.print_screen_info()
signal.signal(signal.SIGTERM, self.signal_quit)
#SIGINT breaks GTK3.. (but there are no py3k servers yet!)
signal.signal(signal.SIGINT, self.signal_quit)
signal.signal(signal.SIGTERM, self.signal_quit)
def start_ready_callbacks():
for x in self._when_ready:
try:
Expand Down

0 comments on commit 586b026

Please sign in to comment.