1
0
mirror of https://github.com/irssi/irssi.git synced 2024-12-04 14:46:39 -05:00

Simplify recode target computation.

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@4773 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Emanuele Giaquinta 2008-03-15 14:51:06 +00:00 committed by exg
parent 52053f1717
commit 8ccdc7267f

View File

@ -291,13 +291,13 @@ static void irc_server_event(IRC_SERVER_REC *server, const char *line,
g_return_if_fail(line != NULL); g_return_if_fail(line != NULL);
params = event_get_params(line, 2, NULL, &args); params = event_get_params(line, 2, NULL, &target);
recoded_nick = recode_in(SERVER(server), nick, NULL); recoded_nick = recode_in(SERVER(server), nick, NULL);
if (ischannel(*args) || if (!ischannel(*target)) {
(*args++ == '@' && ischannel(*args))) if (*target == '@' && ischannel(target[1]))
target = args; target++;
else { else
target = recoded_nick; target = recoded_nick;
} }
recoded_line = recode_in(SERVER(server), line, target); recoded_line = recode_in(SERVER(server), line, target);
/* split event / args */ /* split event / args */