diff options
| author | 2009-10-21 23:46:13 +0000 | |
|---|---|---|
| committer | 2009-10-21 23:46:13 +0000 | |
| commit | d8f98565a8617658f610bc94a5d87266930beee4 (patch) | |
| tree | 365a153c59bc8b521b094c27f25b484a69e5154b /src/socket.cpp | |
| parent | Move AllowedPrivs and similar oper information from LocalUser to OperInfo (diff) | |
Use ConfigTagList as a faster access method for access to configuration
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11948 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/socket.cpp')
| -rw-r--r-- | src/socket.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/socket.cpp b/src/socket.cpp index c4be23a60..1666e3e8b 100644 --- a/src/socket.cpp +++ b/src/socket.cpp @@ -108,11 +108,10 @@ int InspIRCd::BindPorts(FailedPortList &failed_ports) int bound = 0; std::vector<ListenSocketBase*> old_ports(ports.begin(), ports.end()); - for (int count = 0;; count++) + ConfigTagList tags = ServerInstance->Config->ConfTags("bind"); + for(ConfigIter i = tags.first; i != tags.second; ++i) { - ConfigTag* tag = ServerInstance->Config->ConfValue("bind", count); - if (!tag) - break; + ConfigTag* tag = i->second; std::string porttag = tag->getString("port"); std::string Addr = tag->getString("address"); std::string Type = tag->getString("type"); |
