1
0
forked from bip/bip

Be less demanding on the PONG reply to work with 2ch network.

This commit is contained in:
nohar 2007-01-27 15:07:24 +00:00
parent a31562f519
commit 27e6f3a50f

View File

@ -355,7 +355,9 @@ int irc_dispatch_server(struct link_server *server, struct line *line)
free(resps); free(resps);
ret = OK_FORGET; ret = OK_FORGET;
} else if (strcmp(line->elemv[0], "PONG") == 0) { } else if (strcmp(line->elemv[0], "PONG") == 0) {
if (line->elemc == 3 && strcmp(line->elemv[2], S_PING) == 0) { /* not all server reply with PONG <servername> <our string>
* so we blindly assume the PONG is ours. */
if (line->elemc == 3) {
if (server->laginit_ts != -1) { if (server->laginit_ts != -1) {
irc_compute_lag(server); irc_compute_lag(server);
irc_lag_init(server); irc_lag_init(server);