summary refs log tree commit diff
path: root/chat.h
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-02-08 01:14:41 -0500
committerJune McEnroe <june@causal.agency>2020-02-08 01:14:41 -0500
commitfda510b8761f487c36988eb70a6d95bd0d583aed (patch)
treefa9ee4f4ef8ce2c3d8daca8e0b66bff9a25bb6b3 /chat.h
parentHandle KICK (diff)
downloadcatgirl-fda510b8761f487c36988eb70a6d95bd0d583aed.tar.gz
catgirl-fda510b8761f487c36988eb70a6d95bd0d583aed.zip
Handle ID overflow
idk just shove it all in <network>.
Diffstat (limited to 'chat.h')
-rw-r--r--chat.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/chat.h b/chat.h
index bd36d27..081370e 100644
--- a/chat.h
+++ b/chat.h
@@ -49,6 +49,7 @@ static inline size_t idFind(const char *name) {
 static inline size_t idFor(const char *name) {
 	size_t id = idFind(name);
 	if (id) return id;
+	if (idNext == IDCap) return Network;
 	idNames[idNext] = strdup(name);
 	if (!idNames[idNext]) err(EX_OSERR, "strdup");
 	idColors[idNext] = Default;
/td> 2019-07-29Track only the max client fdJune McEnroe 2019-07-28Do basic multiplexing in ingestJune McEnroe 2019-07-28Add empty commandsJune McEnroe 2019-07-28Rename ptee streamJune McEnroe 2019-07-28Remove ptee keybindsJune McEnroe 2019-07-28Import ptee from srcJune McEnroe 2019-07-28Remove old commandsJune McEnroe 2018-04-20Clean up pteeJune McEnroe 2018-04-20Uncommitted changes from months ago :(June McEnroe 2018-02-25Remove winchJune McEnroe 2018-02-25Echo at end of outputJune McEnroe 2018-02-25Add stopJune McEnroe 2018-02-25Switch back to static window sizingJune McEnroe 2018-02-25Add missing includeJune McEnroe 2018-02-25Define rules for multi-object binariesJune McEnroe 2018-02-25Rewrite everythingJune McEnroe 2018-02-22Hardcode path lengths in setupJune McEnroe 2018-02-22Add setup, start commandJune McEnroe 2018-02-22Indent list of streamsJune McEnroe 2018-02-22Add welcome message to ssh-commandJune McEnroe 2018-02-22Sleep before truncationJune McEnroe 2018-02-22List streams if none givenJune McEnroe 2018-02-22Set ForceCommand ssh-commandJune McEnroe 2018-02-22Rename command to ssh-commandJune McEnroe 2018-02-22Add command.shJune McEnroe 2018-02-22Factor out STREAM_SIZE for ingest and broadcastJune McEnroe 2018-02-22Handle EINTR from keventJune McEnroe 2018-02-22Include libutil in chroot.tarJune McEnroe