From 819147178db00008a215670992d0f532dd57f9e5 Mon Sep 17 00:00:00 2001 From: danieldg Date: Tue, 1 Sep 2009 15:06:47 +0000 Subject: Strip SUPPORT_IP6LINKS #define git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11572 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_connectban.cpp | 6 ------ src/modules/m_spanningtree/capab.cpp | 18 ++---------------- src/modules/m_spanningtree/uid.cpp | 2 -- 3 files changed, 2 insertions(+), 24 deletions(-) (limited to 'src/modules') diff --git a/src/modules/m_connectban.cpp b/src/modules/m_connectban.cpp index 19408046f..524edb8a5 100644 --- a/src/modules/m_connectban.cpp +++ b/src/modules/m_connectban.cpp @@ -74,17 +74,11 @@ class ModuleConnectBan : public Module switch (u->GetProtocolFamily()) { - #ifdef SUPPORT_IP6LINKS case AF_INET6: - { range = ipv6_cidr; - } break; - #endif case AF_INET: - { range = ipv4_cidr; - } break; } diff --git a/src/modules/m_spanningtree/capab.cpp b/src/modules/m_spanningtree/capab.cpp index aa4ab5e03..7c37e67eb 100644 --- a/src/modules/m_spanningtree/capab.cpp +++ b/src/modules/m_spanningtree/capab.cpp @@ -65,12 +65,8 @@ void TreeSocket::SendCapabilities() this->WriteLine(line); int ip6 = 0; - int ip6support = 0; #ifdef IPV6 ip6 = 1; -#endif -#ifdef SUPPORT_IP6LINKS - ip6support = 1; #endif std::string extra; /* Do we have sha256 available? If so, we send a challenge */ @@ -92,7 +88,7 @@ void TreeSocket::SendCapabilities() " MAXGECOS="+ConvToStr(ServerInstance->Config->Limits.MaxGecos)+ " MAXAWAY="+ConvToStr(ServerInstance->Config->Limits.MaxAway)+ " IP6NATIVE="+ConvToStr(ip6)+ - " IP6SUPPORT="+ConvToStr(ip6support)+ + " IP6SUPPORT=1"+ " PROTOCOL="+ConvToStr(ProtocolVersion)+extra+ " PREFIX="+ServerInstance->Modes->BuildPrefixes()+ " CHANMODES="+ServerInstance->Modes->GiveModeList(MASK_CHANNEL)+ @@ -148,13 +144,7 @@ bool TreeSocket::Capab(const std::deque ¶ms) else if (params[0] == "END") { std::string reason; - int ip6support = 0; -#ifdef SUPPORT_IP6LINKS - ip6support = 1; -#endif - /* Compare ModuleList and check CapKeys... - * Maybe this could be tidier? -- Brain - */ + /* Compare ModuleList and check CapKeys */ if ((this->ModuleList != this->MyCapabilities()) && (this->ModuleList.length())) { std::string diffIneed = ListDifference(this->ModuleList, this->MyCapabilities()); @@ -174,10 +164,6 @@ bool TreeSocket::Capab(const std::deque ¶ms) this->SendError("CAPAB negotiation failed: "+reason); return false; } - if (((this->CapKeys.find("IP6SUPPORT") == this->CapKeys.end()) && (ip6support)) || ((this->CapKeys.find("IP6SUPPORT") != this->CapKeys.end()) && (this->CapKeys.find("IP6SUPPORT")->second != ConvToStr(ip6support)))) - reason = "We don't both support linking to IPV6 servers"; - if (((this->CapKeys.find("IP6NATIVE") != this->CapKeys.end()) && (this->CapKeys.find("IP6NATIVE")->second == "1")) && (!ip6support)) - reason = "The remote server is IPV6 native, and we don't support linking to IPV6 servers"; if (this->CapKeys.find("PROTOCOL") == this->CapKeys.end()) { reason = "Protocol version not specified"; diff --git a/src/modules/m_spanningtree/uid.cpp b/src/modules/m_spanningtree/uid.cpp index f8efbfd24..40f8e18ab 100644 --- a/src/modules/m_spanningtree/uid.cpp +++ b/src/modules/m_spanningtree/uid.cpp @@ -157,11 +157,9 @@ bool TreeSocket::ParseUID(const std::string &source, std::deque &pa if (params[8][0] != '+') params[8] = "+" + params[8]; -#ifdef SUPPORT_IP6LINKS if (params[6].find_first_of(":") != std::string::npos) _new->SetSockAddr(AF_INET6, params[6].c_str(), 0); else -#endif _new->SetSockAddr(AF_INET, params[6].c_str(), 0); ServerInstance->Users->AddGlobalClone(_new); -- cgit v1.2.3