Module: ngircd.git Branch: master Commit: 8d68fe3f867732cbec094cdf7240a46e631c2838 URL: http://ngircd.barton.de/cgi-bin/gitweb.cgi?p=ngircd.git&a=commit;h=8d68f...
Author: Alexander Barton alex@barton.de Date: Wed Sep 8 00:45:23 2010 +0200
Check_Servers(): skip servers already beeing connected
Let CheckServers() not only skip servers that already have a connection, but also skip servers to which a new connection is already beeing established (SERVER_WAIT state).
---
src/ngircd/conn.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/ngircd/conn.c b/src/ngircd/conn.c index acd50bc..a8e93a2 100644 --- a/src/ngircd/conn.c +++ b/src/ngircd/conn.c @@ -1758,8 +1758,8 @@ Check_Servers(void)
/* Check all configured servers */ for (i = 0; i < MAX_SERVERS; i++) { - if (Conf_Server[i].conn_id > NONE) - continue; /* Already connected */ + if (Conf_Server[i].conn_id != NONE) + continue; /* Already establishing or connected */ if (!Conf_Server[i].host[0] || !Conf_Server[i].port > 0) continue; /* No host and/or port configured */ if (Conf_Server[i].flags & CONF_SFLAG_DISABLED)
ngircd-commits@lists.barton.de