From ff6424a87ce22586c3e2fe1ab57ed3407bef18ca Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Sat, 8 Feb 2020 03:19:56 -0500 Subject: Add /names --- command.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'command.c') diff --git a/command.c b/command.c index 9879dbe..a6434bf 100644 --- a/command.c +++ b/command.c @@ -101,6 +101,12 @@ static void commandNick(size_t id, char *params) { ircFormat("NICK :%s\r\n", params); } +static void commandNames(size_t id, char *params) { + (void)params; + ircFormat("NAMES :%s\r\n", idNames[id]); + replies.names++; +} + static void commandQuery(size_t id, char *params) { if (!params) return; size_t query = idFor(params); @@ -137,6 +143,7 @@ static const struct Handler { { "/debug", commandDebug }, { "/join", commandJoin }, { "/me", commandMe }, + { "/names", commandNames }, { "/nick", commandNick }, { "/notice", commandNotice }, { "/part", commandPart }, -- cgit 1.4.0