From c28e8dc34a04c1c91b268687e9e0b4146d7c3c3a Mon Sep 17 00:00:00 2001 From: w00t Date: Wed, 16 Jan 2008 16:23:43 +0000 Subject: Add a warning about quitting a user twice, and fix a minor brainfart git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8718 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/cull_list.cpp | 4 ++++ src/users.cpp | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/cull_list.cpp b/src/cull_list.cpp index 365cca231..fee326ea3 100644 --- a/src/cull_list.cpp +++ b/src/cull_list.cpp @@ -24,8 +24,12 @@ CullList::CullList(InspIRCd* Instance) : ServerInstance(Instance) void CullList::AddItem(User* user) { if (user->quitting) + { + ServerInstance->Log(DEBUG, "*** Warning *** - You tried to quit a user (%s) twice. Did your module call QuitUser twice?", user->nick); return; + } + user->quitting = true; list.push_back(user); } diff --git a/src/users.cpp b/src/users.cpp index 5f37d08bb..6d902027d 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -708,7 +708,6 @@ void User::QuitUser(InspIRCd* Instance, User *user, const std::string &quitreaso { Instance->Log(DEBUG,"QuitUser: %s '%s'", user->nick, quitreason.c_str()); user->Write("ERROR :Closing link (%s@%s) [%s]", user->ident, user->host, *operreason ? operreason : quitreason.c_str()); - user->quitting = true; user->quietquit = false; user->quitmsg = quitreason; user->operquitmsg = operreason; -- cgit v1.2.3