From e01b03c96383b9e15fe1a2929c4d19869121d0a1 Mon Sep 17 00:00:00 2001 From: Curtis McEnroe Date: Tue, 4 Dec 2018 14:58:14 -0500 Subject: Revert half-working reconnecting stuff --- handle.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'handle.c') diff --git a/handle.c b/handle.c index 973845f..137f859 100644 --- a/handle.c +++ b/handle.c @@ -94,6 +94,14 @@ static void handlePing(char *prefix, char *params) { ircFmt("PONG %s\r\n", params); } +static void handleError(char *prefix, char *params) { + (void)prefix; + (void)params; + // TODO: Show error if unintended disconnect. + uiExit(); + exit(EX_OK); +} + static void handleErrorErroneousNickname(char *prefix, char *params) { char *mesg; parse(prefix, NULL, NULL, NULL, params, 3, 0, NULL, NULL, &mesg); @@ -470,6 +478,7 @@ static const struct { { "401", handleErrorNoSuchNick }, { "432", handleErrorErroneousNickname }, { "433", handleErrorErroneousNickname }, + { "ERROR", handleError }, { "JOIN", handleJoin }, { "KICK", handleKick }, { "NICK", handleNick }, -- cgit 1.4.1-2-gfad0