irc: display message 354 (WHOX) received with missing parameters (closes #1212)

v2.8-utf8proc
Sébastien Helleu 2018-06-23 22:17:18 +02:00
parent 24d2413fdc
commit a5962cf7f5
2 changed files with 19 additions and 1 deletions

View File

@ -45,6 +45,7 @@ Bug fixes::
* core: fix infinite loop in evaluation of strings (issue #1183)
* core: change default value of option weechat.look.window_title from "WeeChat ${info:version}" to empty string (issue #1182)
* fset: fix crash when applying filters after closing the fset buffer (issue #1204)
* irc: display message 354 (WHOX) received with missing parameters (issue #1212)
* irc: always set nick away status on WHO response (sent manually or automatically with server option "away_check")
* irc: fix a crash when calling the function hdata_string on the "prefix" variable in the nick
* irc: fix split of messages when server option "split_msg_max_length" is set to 0 (no split) (issue #1173)

View File

@ -4766,9 +4766,26 @@ IRC_PROTOCOL_CALLBACK(354)
IRC_PROTOCOL_MIN_ARGS(4);
/* silently ignore 354 messages we don't parse (missing infos) */
/*
* if there are less than 11 arguments, we are unable to parse the message,
* some infos are missing but we don't know which ones; in this case we
* just display the message as-is
*/
if (argc < 11)
{
if (argc > 3)
{
weechat_printf_date_tags (
irc_msgbuffer_get_target_buffer (
server, NULL, command, "who", NULL),
date,
irc_protocol_tags (command, "irc_numeric", NULL, NULL),
"%s%s",
weechat_prefix ("network"),
argv_eol[3]);
}
return WEECHAT_RC_OK;
}
pos_attr = argv[8];
pos_hopcount = argv[9];