diff options
| author | 2010-04-12 18:22:44 -0500 | |
|---|---|---|
| committer | 2010-08-03 17:32:42 -0400 | |
| commit | c120a4e37f8d13f0e2540e2534bd7cc36e1f1950 (patch) | |
| tree | a0415046bbde3c687bf87c2b48b9963bdf9861ab /src/modules/m_spanningtree/utils.cpp | |
| parent | Remove unneeded copy of server name for every remote user (diff) | |
Make irc::string faster and less wasteful
Change irc::string from an std::basic_string typedef to a wrapper around
an std::string, to avoid unneeded copies in assign().
Diffstat (limited to 'src/modules/m_spanningtree/utils.cpp')
| -rw-r--r-- | src/modules/m_spanningtree/utils.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/modules/m_spanningtree/utils.cpp b/src/modules/m_spanningtree/utils.cpp index 444fd4825..1cdfa3015 100644 --- a/src/modules/m_spanningtree/utils.cpp +++ b/src/modules/m_spanningtree/utils.cpp @@ -387,10 +387,10 @@ void SpanningTreeUtilities::ReadConfiguration() L->Hidden = tag->getBool("hidden"); if (L->Name.find('.') == std::string::npos) - throw CoreException("The link name '"+assign(L->Name)+"' is invalid and must contain at least one '.' character"); + throw CoreException("The link name '"+L->Name+"' is invalid and must contain at least one '.' character"); if (L->Name.length() > 64) - throw CoreException("The link name '"+assign(L->Name)+"' is longer than 64 characters!"); + throw CoreException("The link name '"+L->Name+"' is longer than 64 characters!"); if (L->Fingerprint.find(':') != std::string::npos) { @@ -411,17 +411,17 @@ void SpanningTreeUtilities::ReadConfiguration() { L->IPAddr = "*"; ValidIPs.push_back("*"); - ServerInstance->Logs->Log("m_spanningtree",DEFAULT,"Configuration warning: Link block " + assign(L->Name) + " has no IP defined! This will allow any IP to connect as this server, and MAY not be what you want."); + ServerInstance->Logs->Log("m_spanningtree",DEFAULT,"Configuration warning: Link block " + L->Name + " has no IP defined! This will allow any IP to connect as this server, and MAY not be what you want."); } if (L->RecvPass.empty()) { - throw CoreException("Invalid configuration for server '"+assign(L->Name)+"', recvpass not defined!"); + throw CoreException("Invalid configuration for server '"+L->Name+"', recvpass not defined!"); } if (L->SendPass.empty()) { - throw CoreException("Invalid configuration for server '"+assign(L->Name)+"', sendpass not defined!"); + throw CoreException("Invalid configuration for server '"+L->Name+"', sendpass not defined!"); } if (L->Name.empty()) @@ -431,7 +431,7 @@ void SpanningTreeUtilities::ReadConfiguration() if (!L->Port) { - ServerInstance->Logs->Log("m_spanningtree",DEFAULT,"Configuration warning: Link block " + assign(L->Name) + " has no port defined, you will not be able to /connect it."); + ServerInstance->Logs->Log("m_spanningtree",DEFAULT,"Configuration warning: Link block " + L->Name + " has no port defined, you will not be able to /connect it."); } } |
