Skip to content

Commit

Permalink
Move the check for 4xx numeric for join failures last, so
Browse files Browse the repository at this point in the history
that the CHANNEL_REC is still around when handlers for
specific numerics are executed. This allows removing the
ugly special case for 437; I will also use this for 470
(channel forwarding).


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@4572 dbcabf3a-b0e7-0310-adc4-f8d773084564
  • Loading branch information
Jilles Tjoelker authored and jilles committed Jul 6, 2007
1 parent 0b8bee0 commit 8312144
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/irc/core/channel-events.c
Expand Up @@ -60,8 +60,7 @@ static void irc_server_event(IRC_SERVER_REC *server, const char *line)
indicate that the join failed. */
params = event_get_params(line, 3, &numeric, NULL, &channel);

/* 437 is handled specially in src/irc/core/channel-rejoin.c */
if (numeric[0] == '4' && (numeric[1] != '3' || numeric[2] != '7'))
if (numeric[0] == '4')
check_join_failure(server, channel);

g_free(params);
Expand Down Expand Up @@ -360,7 +359,7 @@ void channel_events_init(void)
{
settings_add_bool("misc", "join_auto_chans_on_invite", TRUE);

signal_add_first("server event", (SIGNAL_FUNC) irc_server_event);
signal_add_last("server event", (SIGNAL_FUNC) irc_server_event);
signal_add_first("event 403", (SIGNAL_FUNC) event_no_such_channel); /* no such channel */
signal_add_first("event 407", (SIGNAL_FUNC) event_duplicate_channel); /* duplicate channel */

Expand Down

0 comments on commit 8312144

Please sign in to comment.