diff options
author | Adam <Adam@anope.org> | 2011-04-25 15:58:46 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2011-04-25 15:58:46 -0400 |
commit | 0cdc628db05cc7391c6114c46c52d65d90603571 (patch) | |
tree | 5f985f006e2df90488c283fff639f88a5d9cef68 /src/chanserv.cpp | |
parent | 4a733c93d45e0ca5d757abf826d65bc1cbaf610e (diff) |
Fixed crash when certain nicks expire
Diffstat (limited to 'src/chanserv.cpp')
-rw-r--r-- | src/chanserv.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/chanserv.cpp b/src/chanserv.cpp index e519cb8b2..06ef6e83c 100644 --- a/src/chanserv.cpp +++ b/src/chanserv.cpp @@ -406,9 +406,10 @@ void expire_chans() // XXX this is slightly inefficient void cs_remove_nick(NickCore *nc) { - for (registered_channel_map::const_iterator it = RegisteredChannelList.begin(), it_end = RegisteredChannelList.end(); it != it_end; ++it) + for (registered_channel_map::const_iterator it = RegisteredChannelList.begin(); it != RegisteredChannelList.end();) { ChannelInfo *ci = it->second; + ++it; ChanAccess *access = ci->GetAccess(nc); if (access) |