From f36915790674275627cf8eb68024e17539ee04fa Mon Sep 17 00:00:00 2001 From: Adam Date: Fri, 11 Apr 2014 16:10:30 -0400 Subject: Use OnChanRegistered instead of OnCreateChan to set default mlocks. Because OnCreateChan is called from ChannelInfo's constructor, during DB loading it could cause mode locks to be unserialized without having all channels loaded, which breaks things. --- modules/commands/cs_mode.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/commands/cs_mode.cpp') diff --git a/modules/commands/cs_mode.cpp b/modules/commands/cs_mode.cpp index a13610d23..941a6d183 100644 --- a/modules/commands/cs_mode.cpp +++ b/modules/commands/cs_mode.cpp @@ -951,7 +951,7 @@ class CSMode : public Module } } - void OnCreateChan(ChannelInfo *ci) anope_override + void OnChanRegistered(ChannelInfo *ci) anope_override { ModeLocks *ml = modelocks.Require(ci); Anope::string mlock; -- cgit