summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--handle.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/handle.c b/handle.c
index 35c1e5f..ae3dbfa 100644
--- a/handle.c
+++ b/handle.c
@@ -103,7 +103,7 @@ static void handlePing(char *prefix, char *params) {
 	ircFmt("PONG %s\r\n", params);
 }
 
-static void handleReplyErroneousNickname(char *prefix, char *params) {
+static void handleErrorErroneousNickname(char *prefix, char *params) {
 	char *mesg;
 	shift(prefix, NULL, NULL, NULL, params, 3, 0, NULL, NULL, &mesg);
 	uiFmt(TagStatus, UIHot, "You can't use that name here: \"%s\"", mesg);
@@ -140,7 +140,7 @@ static void handleReplyWhoisUser(char *prefix, char *params) {
 	whoisColor = formatColor(user);
 	uiFmt(
 		TagStatus, UIWarm,
-		"\3%d%s\3 is %s@%s \"%s\"",
+		"\3%d%s\3 is %s@%s, \"%s\"",
 		whoisColor, nick, user, host, real
 	);
 }
@@ -182,6 +182,12 @@ static void handleReplyWhoisChannels(char *prefix, char *params) {
 	uiFmt(TagStatus, UIWarm, "\3%d%s\3 is in %s", whoisColor, nick, chans);
 }
 
+static void handleErrorNoSuchNick(char *prefix, char *params) {
+	char *nick, *mesg;
+	shift(prefix, NULL, NULL, NULL, params, 3, 0, NULL, &nick, &mesg);
+	uiFmt(TagStatus, UIWarm, "%s, \"%s\"", mesg, nick);
+}
+
 static void handleJoin(char *prefix, char *params) {
 	char *nick, *user, *chan;
 	shift(prefix, &nick, &user, NULL, params, 1, 0, &chan);
@@ -464,8 +470,9 @@ static const struct {
 	{ "366", handleReplyEndOfNames },
 	{ "372", handleReplyMOTD },
 	{ "375", handleReplyMOTD },
-	{ "432", handleReplyErroneousNickname },
-	{ "433", handleReplyErroneousNickname },
+	{ "401", handleErrorNoSuchNick },
+	{ "432", handleErrorErroneousNickname },
+	{ "433", handleErrorErroneousNickname },
 	{ "JOIN", handleJoin },
 	{ "KICK", handleKick },
 	{ "NICK", handleNick },
itle='2020-08-27 17:24:39 -0400'>2020-08-27contrib/palaver: Fix documented database pathJune McEnroe 2020-08-27contrib/palaver: Remove rc scriptJune McEnroe 2020-08-27contrib/palaver: Fix database search and creationJune McEnroe 2020-08-27contrib/palaver: Use pounce's XDG directoryJune McEnroe 2020-08-27contrib/palaver: Only allow HTTPSJune McEnroe 2020-08-25Support the pounce_env rc variableJune McEnroe 2020-08-25Remove deprecated option namesJune McEnroe 2020-08-25Document configuration and data file searchJune McEnroe 2020-08-24Use dataOpen for save fileJune McEnroe 2020-08-24Use configOpen to load localCAJune McEnroe 2020-08-24Use configPath to load client cert/privJune McEnroe 2020-08-24Use configOpen in getopt_configJune McEnroe 2020-08-24Import xdg.c from catgirlJune McEnroe 2020-08-23Replace “RAND_bytes” by “getentropy”Issam E. Maghni 2020-08-16contrib/palaver: Add no message preview flagsJune McEnroe 2020-08-13contrib/palaver: Don't set channel for PMsJune McEnroe 2020-08-13Fix unintended interception of NICK after registrationJune McEnroe 2020-08-12Add Additional Components section to READMEJune McEnroe 2020-08-12Document -L / palaver optionJune McEnroe 2020-08-11contrib/palaver: Document service configurationJune McEnroe 2020-08-11contrib/palaver: Add install target and rc scriptJune McEnroe 2020-08-11contrib/palaver: Implement command and notificationsJune McEnroe