diff options
-rw-r--r-- | src/modules/m_spanningtree.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp index 44786923c..dc50140b2 100644 --- a/src/modules/m_spanningtree.cpp +++ b/src/modules/m_spanningtree.cpp @@ -2622,6 +2622,11 @@ class TreeSocket : public InspSocket userrec* y = Srv->FindNick(prefix); if (y) { + TreeServer* n = FindServer(y->server); + if (n) + { + n->DelUser(y); + } Srv->QuitUser(y,"Nickname collision"); } return DoOneToAllButSenderRaw(line,sourceserv,prefix,command,params); @@ -3740,6 +3745,17 @@ class ModuleSpanningTree : public Module params.push_back(dest->nick); params.push_back(":"+reason); DoOneToMany(source->nick,"KILL",params); + /* NOTE: We must remove the user from the servers list here. + * If we do not, there is a chance the user could hang around + * in the list if there is a desync for example (this would + * not be good). + * Part of the 'random crash on netsplit' tidying up. -Brain + */ + TreeServer* n = FindServer(dest->server); + if (n) + { + n->DelUser(dest); + } } virtual void OnRehash(const std::string ¶meter) |