summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/inspircd.cpp22
1 files changed, 17 insertions, 5 deletions
diff --git a/src/inspircd.cpp b/src/inspircd.cpp
index a16898d53..21113b4f4 100644
--- a/src/inspircd.cpp
+++ b/src/inspircd.cpp
@@ -2458,11 +2458,23 @@ long chancount(void)
long count_servs(void)
{
int c = 0;
- //for (int j = 0; j < 255; j++)
- //{
- // if (servers[j] != NULL)
- // c++;
- //}
+ for (int j = 0; j < 255; j++)
+ {
+ for (int i = 0; i < 32; i++)
+ {
+ if (me[i] != NULL)
+ {
+ for (vector<ircd_connector>::iterator j = me[i]->connectors.begin(); j != me[i]->connectors.end(); j++)
+ {
+ if (strcasecmp(j->GetServerName().c_str(),ServerName))
+ {
+ c++;
+ }
+ }
+ }
+ }
+
+ }
return c;
}