Fix for delete-when-we-shouldnt bug similar to what stskeeps found yesterday

git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7787 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
brain 2007-08-21 18:41:24 +00:00
parent 74f26a0375
commit 3499c913a0

View File

@ -553,7 +553,8 @@ void ModuleSpanningTree::ConnectServer(Link* x)
else
{
ServerInstance->SNO->WriteToSnoMask('l',"CONNECT: Error connecting \002%s\002: %s.",x->Name.c_str(),strerror(errno));
delete newsocket;
if (ServerInstance->SocketCull.find(newsocket) == ServerInstance->SocketCull.end())
ServerInstance->SocketCull[newsocket] = newsocket;
Utils->DoFailOver(x);
}
}