From eacee66e2c4c0879dda7cf67641ca889d1b39870 Mon Sep 17 00:00:00 2001 From: brain Date: Wed, 30 Nov 2005 13:32:30 +0000 Subject: Fixed nick collision stuff git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2053 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_spanningtree.cpp | 32 ++------------------------------ 1 file changed, 2 insertions(+), 30 deletions(-) (limited to 'src/modules/m_spanningtree.cpp') diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp index 92681eca9..f712bf8e3 100644 --- a/src/modules/m_spanningtree.cpp +++ b/src/modules/m_spanningtree.cpp @@ -562,36 +562,8 @@ class TreeSocket : public InspSocket { // nick collision log(DEBUG,"Nick collision on %s!%s@%s: %lu %lu",tempnick,ident.c_str(),host.c_str(),(unsigned long)age,(unsigned long)iter->second->age); - if (age <= iter->second->age) - { - log (DEBUG,"*** COLLISION: Remote client is older"); - // remote client is older - // if hosts are identical, kill the remote, - // else kill the local. We must send KILL for - // removal of remote users. - if (!strcmp(iter->second->host,host.c_str())) - { - // kill the remote by sending KILL, - // and ABORT to stop it being introduced here. - log(DEBUG,"**** LOCATION ONE"); - this->WriteLine(":"+Srv->GetServerName()+" KILL "+tempnick+" :Killed (Nickname collision from "+Srv->GetServerName()+")"); - return true; - } - else - { - log(DEBUG,"*** LOCATION TWO"); - // kill our local and continue to let the remote be introduced - Srv->QuitUser(iter->second,"Killed (Nickname collision from "+source+")"); - } - } - else - { - log(DEBUG,"*** COLLISION: Remote client is newer"); - // remote is newer, kill it and bail to stop it being introduced - this->WriteLine(":"+Srv->GetServerName()+" KILL "+tempnick+" :Killed (Nickname collision from "+Srv->GetServerName()+")"); - log(DEBUG,"*** COLLIDE COMPLETED"); - return true; - } + Srv->QuitUser(iter->second,"Killed (Nickname collision from "+source+")"); + return true; } clientlist[tempnick] = new userrec(); -- cgit v1.2.3