summaryrefslogtreecommitdiff
path: root/src/userprocess.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-07-22 10:53:17 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-07-22 10:53:17 +0000
commit93ddad5bdbd70844ef713126d930f561ff0e0437 (patch)
treea1db001be9254bb84bbfed7b570a9d0984d25114 /src/userprocess.cpp
parent06341fb5b8d1c416da762a437827c1eba2b32ca0 (diff)
Make OnCheckReady safe against the user being killed, SO LONG AS THE MODULE WHICH D/C'S THE USER RETURNS FALSE
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4501 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/userprocess.cpp')
-rw-r--r--src/userprocess.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/userprocess.cpp b/src/userprocess.cpp
index a6f86d2f2..c4c43ca16 100644
--- a/src/userprocess.cpp
+++ b/src/userprocess.cpp
@@ -360,6 +360,10 @@ void DoBackgroundUserStuff(time_t TIME)
FullConnectUser(curr,&GlobalGoners);
continue;
}
+
+ if ((fd_ref_table[cfd] != curr) && (curr))
+ /* Somebody blatted this user in OnCheckReady (!) */
+ continue;
if ((curr->dns_done) && (curr->registered == 3) && (AllModulesReportReady(curr)))
{
@@ -368,6 +372,10 @@ void DoBackgroundUserStuff(time_t TIME)
ZapThisDns(curr->fd);
continue;
}
+
+ if ((fd_ref_table[cfd] != curr) && (curr))
+ /* Somebody blatted this user in OnCheckReady (!) */
+ continue;
// It's time to PING this user. Send them a ping.
if ((TIME > curr->nping) && (curr->registered == 7))