summaryrefslogtreecommitdiff
path: root/src/configreader.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/configreader.cpp')
-rw-r--r--src/configreader.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/configreader.cpp b/src/configreader.cpp
index 04763cbab..bbf3adf59 100644
--- a/src/configreader.cpp
+++ b/src/configreader.cpp
@@ -261,7 +261,7 @@ void ServerConfig::CrossCheckConnectBlocks(ServerConfig* current)
for(ClassVector::iterator i = current->Classes.begin(); i != current->Classes.end(); ++i)
{
ConnectClass* c = *i;
- std::string typeMask = (c->type == CC_ALLOW) ? "a" : "d";
+ std::string typeMask = (c->type == CC_ALLOW) ? "a" : (c->type == CC_DENY) ? "d" : "n";
typeMask += c->host;
oldBlocksByMask[typeMask] = c;
}
@@ -335,7 +335,9 @@ void ServerConfig::CrossCheckConnectBlocks(ServerConfig* current)
}
else
{
- throw CoreException("Connect class must have an allow or deny mask at " + tag->getTagLocation());
+ type = CC_NAMED;
+ mask = name;
+ typeMask = 'n' + mask;
}
ClassMap::iterator dupMask = newBlocksByMask.find(typeMask);
if (dupMask != newBlocksByMask.end())