From 64c8881fe5811491451442f273426d87b6c56ae3 Mon Sep 17 00:00:00 2001 From: peavey Date: Thu, 21 Dec 2006 01:48:50 +0000 Subject: Proper fix for CS server crash, forgot to delete chanrec* from users chanlist on PurgeEmptyChannels() git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6052 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/users.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src') diff --git a/src/users.cpp b/src/users.cpp index 93f1c6d84..45071d231 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -1667,9 +1667,6 @@ void userrec::WriteCommonExcept(const std::string &text) for (UCListIter v = this->chans.begin(); v != this->chans.end(); v++) { - chanrec* c = ServerInstance->FindChan(v->first->name); - if (!c) - continue; CUList *ulist = v->first->GetUsers(); for (CUList::iterator i = ulist->begin(); i != ulist->end(); i++) { @@ -1971,6 +1968,7 @@ void userrec::PurgeEmptyChannels() FOREACH_MOD(I_OnChannelDelete,OnChannelDelete(i2->second)); DELETE(i2->second); ServerInstance->chanlist.erase(i2); + this->chans.erase(*n); } } -- cgit v1.2.3