mirror of
https://github.com/anope/anope.git
synced 2026-07-01 09:36:36 +02:00
Use I_OnUserQuit for os_session because I_OnPreUserLogoff gets called too late, after the users server can be gone. Fix a couple other small things
This commit is contained in:
@@ -463,7 +463,7 @@ module { name = "help" }
|
||||
* This module allows granting users services operator privileges and possibly IRC Operator
|
||||
* privileges based on an external SQL database using a custom query.
|
||||
*/
|
||||
module
|
||||
#module
|
||||
{
|
||||
name = "m_sql_oper"
|
||||
|
||||
@@ -560,7 +560,7 @@ module { name = "m_rewrite" }
|
||||
*
|
||||
* This module uses SSL to connect to the uplink server(s).
|
||||
*/
|
||||
module
|
||||
#module
|
||||
{
|
||||
name = "m_ssl"
|
||||
|
||||
|
||||
@@ -640,7 +640,7 @@ class OSSession : public Module
|
||||
{
|
||||
this->SetPermanent(true);
|
||||
|
||||
Implementation i[] = { I_OnReload, I_OnUserConnect, I_OnPreUserLogoff };
|
||||
Implementation i[] = { I_OnReload, I_OnUserConnect, I_OnUserQuit };
|
||||
ModuleManager::Attach(i, this, sizeof(i) / sizeof(Implementation));
|
||||
ModuleManager::SetPriority(this, PRIORITY_FIRST);
|
||||
}
|
||||
@@ -734,7 +734,7 @@ class OSSession : public Module
|
||||
catch (const SocketException &) { }
|
||||
}
|
||||
|
||||
void OnPreUserLogoff(User *u) anope_override
|
||||
void OnUserQuit(User *u, const Anope::string &msg) anope_override
|
||||
{
|
||||
if (!session_limit || !u->server || u->server->IsULined())
|
||||
return;
|
||||
|
||||
@@ -815,7 +815,8 @@ class ProtoInspIRCd : public Module
|
||||
|
||||
void OnChannelCreate(Channel *c) anope_override
|
||||
{
|
||||
this->OnChanRegistered(c->ci);
|
||||
if (c->ci)
|
||||
this->OnChanRegistered(c->ci);
|
||||
}
|
||||
|
||||
void OnChanRegistered(ChannelInfo *ci) anope_override
|
||||
|
||||
+1
-1
@@ -237,7 +237,7 @@ Conf::Conf() : Block("")
|
||||
ot->AddCommand(str);
|
||||
|
||||
spacesepstream privstr(privs);
|
||||
for (Anope::string str; cmdstr.GetToken(str);)
|
||||
for (Anope::string str; privstr.GetToken(str);)
|
||||
ot->AddPriv(str);
|
||||
|
||||
commasepstream inheritstr(inherits);
|
||||
|
||||
Reference in New Issue
Block a user