diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_cgiirc.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/modules/m_cgiirc.cpp b/src/modules/m_cgiirc.cpp index ec6d5d398..290f55d22 100644 --- a/src/modules/m_cgiirc.cpp +++ b/src/modules/m_cgiirc.cpp @@ -289,6 +289,7 @@ public: if(user->GetExt("cgiirc_webirc_ip", webirc_ip)) { bool valid=false; + user->RemoveCloneCounts(); #ifdef IPV6 valid = (inet_pton(AF_INET6, webirc_ip->c_str(), &((sockaddr_in6*)user->ip)->sin6_addr) > 0); @@ -302,6 +303,9 @@ public: delete webirc_ip; user->InvalidateCache(); user->Shrink("cgiirc_webirc_ip"); + ServerInstance->AddLocalClone(user); + ServerInstance->AddGlobalClone(user); + user->CheckClass(); } } @@ -316,6 +320,7 @@ public: user->InvalidateCache(); bool valid = false; + user->RemoveCloneCounts(); #ifdef IPV6 if (user->GetProtocolFamily() == AF_INET6) valid = (inet_pton(AF_INET6, user->password, &((sockaddr_in6*)user->ip)->sin6_addr) > 0); @@ -325,6 +330,10 @@ public: if (inet_aton(user->password, &((sockaddr_in*)user->ip)->sin_addr)) valid = true; #endif + ServerInstance->AddLocalClone(user); + ServerInstance->AddGlobalClone(user); + user->CheckClass(); + if (valid) { /* We were given a IP in the password, we don't do DNS so they get this is as their host as well. */ @@ -381,13 +390,16 @@ public: user->Extend("cgiirc_realhost", new std::string(user->host)); user->Extend("cgiirc_realip", new std::string(user->GetIPString())); + user->RemoveCloneCounts(); #ifdef IPV6 if (user->GetProtocolFamily() == AF_INET6) inet_pton(AF_INET6, newip, &((sockaddr_in6*)user->ip)->sin6_addr); else #endif inet_aton(newip, &((sockaddr_in*)user->ip)->sin_addr); - + ServerInstance->AddLocalClone(user); + ServerInstance->AddGlobalClone(user); + user->CheckClass(); try { strlcpy(user->host, newip, 16); |