summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-10-14 19:26:42 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-10-14 19:26:42 +0000
commit4d908f4bc04e74f9fd5f1deb845e56da4db5bc6c (patch)
treec344943c09226e586f90c2bd121db18920825e54 /src
parent8e18181698f54b0dabb4be3c4c7a53b824fb5933 (diff)
Put this back how it was, it didnt help with the fix last night which turned out to be something else
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8190 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/users.cpp20
1 files changed, 8 insertions, 12 deletions
diff --git a/src/users.cpp b/src/users.cpp
index 31244f987..feadc7b18 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -917,18 +917,6 @@ void userrec::AddClient(InspIRCd* Instance, int socket, int port, bool iscached,
New->dhost[j] = New->host[j] = *temp;
New->dhost[j] = New->host[j] = 0;
- if (socket > -1)
- {
- if (!Instance->SE->AddFd(New))
- {
- Instance->Log(DEBUG,"ERROR: Could not add new user %s!%s@%s to the socket engine!!!", New->nick, New->ident, New->host);
- close(socket);
- shutdown(socket,2);
- delete New;
- return;
- }
- }
-
Instance->AddLocalClone(New);
Instance->AddGlobalClone(New);
@@ -992,6 +980,14 @@ void userrec::AddClient(InspIRCd* Instance, int socket, int port, bool iscached,
}
}
+ if (socket > -1)
+ {
+ if (!Instance->SE->AddFd(New))
+ {
+ userrec::QuitUser(Instance, New, "Internal error handling connection");
+ }
+ }
+
/* NOTE: even if dns lookups are *off*, we still need to display this.
* BOPM and other stuff requires it.
*/