summary refs log tree commit diff
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2019-10-31 18:25:01 -0400
committerJune McEnroe <june@causal.agency>2019-10-31 18:25:01 -0400
commitb8011ca5ba386aa1e16e8cf255e9e19375151950 (patch)
treecdc517b8c55e7012590c9cee51977dd91fabc4c8
parentShrink client buffer size (diff)
downloadpounce-b8011ca5ba386aa1e16e8cf255e9e19375151950.tar.gz
pounce-b8011ca5ba386aa1e16e8cf255e9e19375151950.zip
Send clients their own QUIT on shutdown
-rw-r--r--bounce.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bounce.c b/bounce.c
index 18b205e..b89e90a 100644
--- a/bounce.c
+++ b/bounce.c
@@ -284,7 +284,10 @@ int main(int argc, char *argv[]) {
 	serverFormat("QUIT :%s\r\n", quit);
 	for (size_t i = 0; i < event.len; ++i) {
 		if (event.clients[i]) {
-			clientFormat(event.clients[i], "ERROR :Disconnecting\r\n");
+			clientFormat(
+				event.clients[i], ":%s QUIT :%s\r\nERROR :Disconnecting\r\n",
+				stateEcho(), quit
+			);
 			clientFree(event.clients[i]);
 		}
 		close(event.fds[i].fd);
1b724b7dc3c7a3b0b426&follow=1'>Don't dump tiles in coreJune McEnroe 2017-07-31Use designated initializers for messagesJune McEnroe I did not realize this syntax was so powerful. 2017-07-31Show other clients' cursorsJune McEnroe Also unfuck removing on send failure. 2017-07-31Perform enter as two moves rather than a loopJune McEnroe 2017-07-31Track tile access countsJune McEnroe 2017-07-31Adjust move speed in clientJune McEnroe 2017-07-31Handle large movesJune McEnroe 2017-07-30Optimize builds for chrootJune McEnroe 2017-07-30Persist bright across color changesJune McEnroe 2017-07-30Add index.htmlJune McEnroe 2017-07-30Add snapshot.shJune McEnroe 2017-07-30Fix termcap patch for background colorsJune McEnroe 2017-07-30Update helpJune McEnroe 2017-07-30Fix help to track colorJune McEnroe 2017-07-30Support background colorsJune McEnroe 2017-07-30Track color only client-sideJune McEnroe 2017-07-30Add ostensible support for background colorsJune McEnroe 2017-07-30Add tile create and access timestampsJune McEnroe 2017-07-30Assert stable struct Tile field offsetsJune McEnroe 2017-07-30Add chroot.shJune McEnroe 2017-07-30Add ` commandJune McEnroe 2017-07-30Add sshd_configJune McEnroe 2017-07-30Add termcap patchJune McEnroe