diff options
author | Nicholas Marriott <nicm@openbsd.org> | 2009-07-30 16:16:19 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@openbsd.org> | 2009-07-30 16:16:19 +0000 |
commit | 479d614884f66e9fa11f1292a2ef36991da46c1d (patch) | |
tree | c9bac93767d7dc741dfa5b047ceb248ff9af56ed /client.c | |
parent | 071494d8faff83287088bbdcc38db1414c0123b9 (diff) | |
download | rtmux-479d614884f66e9fa11f1292a2ef36991da46c1d.tar.gz rtmux-479d614884f66e9fa11f1292a2ef36991da46c1d.tar.bz2 rtmux-479d614884f66e9fa11f1292a2ef36991da46c1d.zip |
Tell the server when the client gets SIGTERM so it can clean up the terminal
properly, rather than just exiting.
Diffstat (limited to 'client.c')
-rw-r--r-- | client.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -143,7 +143,9 @@ client_main(struct client_ctx *cctx) logfile("client"); - while (!sigterm) { + for (;;) { + if (sigterm) + client_write_server(cctx, MSG_EXITING, NULL, 0); if (sigchld) { waitpid(WAIT_ANY, NULL, WNOHANG); sigchld = 0; |