diff options
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r-- | src/modules/m_spanningtree/main.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_spanningtree/resolvers.cpp | 4 | ||||
-rw-r--r-- | src/modules/m_spanningtree/utils.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_spanningtree/utils.h | 10 |
4 files changed, 7 insertions, 11 deletions
diff --git a/src/modules/m_spanningtree/main.cpp b/src/modules/m_spanningtree/main.cpp index 761343bb1..b8540cf27 100644 --- a/src/modules/m_spanningtree/main.cpp +++ b/src/modules/m_spanningtree/main.cpp @@ -306,7 +306,7 @@ void ModuleSpanningTree::ConnectServer(Link* x, Autoconnect* y) { try { - bool cached; + bool cached = false; ServernameResolver* snr = new ServernameResolver(Utils, x->IPAddr, x, cached, start_type, y); ServerInstance->AddResolver(snr, cached); } diff --git a/src/modules/m_spanningtree/resolvers.cpp b/src/modules/m_spanningtree/resolvers.cpp index b69c5c29e..d7c4c5227 100644 --- a/src/modules/m_spanningtree/resolvers.cpp +++ b/src/modules/m_spanningtree/resolvers.cpp @@ -71,7 +71,7 @@ void ServernameResolver::OnError(ResolverError e, const std::string &errormessag /* Ooops! */ if (query == DNS_QUERY_AAAA) { - bool cached; + bool cached = false; ServernameResolver* snr = new ServernameResolver(Utils, host, MyLink, cached, DNS_QUERY_A, myautoconnect); ServerInstance->AddResolver(snr, cached); return; @@ -102,7 +102,7 @@ void SecurityIPResolver::OnError(ResolverError e, const std::string &errormessag { if (query == DNS_QUERY_AAAA) { - bool cached; + bool cached = false; SecurityIPResolver* res = new SecurityIPResolver(mine, Utils, host, MyLink, cached, DNS_QUERY_A); ServerInstance->AddResolver(res, cached); return; diff --git a/src/modules/m_spanningtree/utils.cpp b/src/modules/m_spanningtree/utils.cpp index 8b078220c..471026887 100644 --- a/src/modules/m_spanningtree/utils.cpp +++ b/src/modules/m_spanningtree/utils.cpp @@ -314,7 +314,7 @@ void SpanningTreeUtilities::RefreshIPCache() { try { - bool cached; + bool cached = false; SecurityIPResolver* sr = new SecurityIPResolver(Creator, this, L->IPAddr, L, cached, DNS_QUERY_AAAA); ServerInstance->AddResolver(sr, cached); } diff --git a/src/modules/m_spanningtree/utils.h b/src/modules/m_spanningtree/utils.h index ace33ad3b..7d5ffa216 100644 --- a/src/modules/m_spanningtree/utils.h +++ b/src/modules/m_spanningtree/utils.h @@ -36,14 +36,10 @@ class SpanningTreeUtilities; /* This hash_map holds the hash equivalent of the server * tree, used for rapid linear lookups. */ -#if defined(WINDOWS) && !defined(HASHMAP_DEPRECATED) - typedef nspace::hash_map<std::string, TreeServer*, nspace::hash_compare<std::string, std::less<std::string> > > server_hash; +#ifdef HASHMAP_DEPRECATED + typedef nspace::hash_map<std::string, TreeServer*, nspace::insensitive, irc::StrHashComp> server_hash; #else - #ifdef HASHCOMP_DEPRECATED - typedef nspace::hash_map<std::string, TreeServer*, nspace::insensitive, irc::StrHashComp> server_hash; - #else - typedef nspace::hash_map<std::string, TreeServer*, nspace::hash<std::string>, irc::StrHashComp> server_hash; - #endif + typedef nspace::hash_map<std::string, TreeServer*, nspace::hash<std::string>, irc::StrHashComp> server_hash; #endif typedef std::map<TreeServer*,TreeServer*> TreeServerList; |