RFC 1459 specifies that the PONG message may have 1 or 2 parameters.

This commit is contained in:
Zach Wily 2010-04-07 22:12:26 +01:00 committed by Arnaud Cornet
parent f995c1f537
commit 4d3ee53e7b
1 changed files with 1 additions and 1 deletions

View File

@ -370,7 +370,7 @@ int irc_dispatch_server(bip_t *bip, struct link_server *server,
} else if (irc_line_elem_equals(line, 0, "PONG")) {
/* not all server reply with PONG <servername> <our string>
* so we blindly assume the PONG is ours. */
if (irc_line_count(line) == 3) {
if (irc_line_count(line) == 2 || irc_line_count(line) == 3) {
if (server->laginit_ts != -1) {
irc_compute_lag(server);
irc_lag_init(server);