1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-12 14:14:48 +02:00

irc: require nick in "away" command callback

This commit is contained in:
Sébastien Helleu
2021-10-14 23:21:27 +02:00
parent bf8c85f422
commit 8d12187f3d
2 changed files with 5 additions and 0 deletions
+1
View File
@@ -544,6 +544,7 @@ IRC_PROTOCOL_CALLBACK(away)
struct t_irc_nick *ptr_nick;
IRC_PROTOCOL_MIN_PARAMS(0);
IRC_PROTOCOL_CHECK_NICK;
for (ptr_channel = server->channels; ptr_channel;
ptr_channel = ptr_channel->next_channel)
@@ -725,6 +725,10 @@ TEST(IrcProtocolWithServer, away)
SRV_INIT_JOIN;
/* missing nick */
RECV("AWAY");
CHECK_ERROR_NICK("away");
ptr_nick = ptr_server->channels->nicks;
LONGS_EQUAL(0, ptr_nick->away);