aboutsummaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorGravatar brain2007-01-15 23:49:24 +0000
committerGravatar brain2007-01-15 23:49:24 +0000
commitd769fef63f2f9ccd929aa51fda3c3da7ec389181 (patch)
treed8277ddfdbb86a4825ec09e3ac8011a9fdffa51f /src/modules
parentRemove some debug (im on a crusade to make debug mode useful, but at the same... (diff)
Crusade to remove debug from stable and tested parts of the core and base modules.
Most of the code here being de-noised hasnt had a crash or bug in it for many months, if not a year so the debug output is useless noise in the logfile when trying to trace a bug in a REAL problem area. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6356 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_chanprotect.cpp18
-rw-r--r--src/modules/m_conn_umodes.cpp3
-rw-r--r--src/modules/m_opermodes.cpp2
-rw-r--r--src/modules/m_override.cpp7
4 files changed, 1 insertions, 29 deletions
diff --git a/src/modules/m_chanprotect.cpp b/src/modules/m_chanprotect.cpp
index f7c05572f..a1d580180 100644
--- a/src/modules/m_chanprotect.cpp
+++ b/src/modules/m_chanprotect.cpp
@@ -372,10 +372,7 @@ class ModuleChanProtect : public Module
// to make it clearer that +q has been given, send that one user the +q notice
// so that their client's syncronization and their sanity are left intact.
user->WriteServ("MODE %s +q %s",channel->name,user->nick);
- if (user->Extend("cm_founder_"+std::string(channel->name),fakevalue))
- {
- ServerInstance->Log(DEBUG,"Marked user "+std::string(user->nick)+" as founder for "+std::string(channel->name));
- }
+ user->Extend("cm_founder_"+std::string(channel->name),fakevalue);
}
}
}
@@ -385,8 +382,6 @@ class ModuleChanProtect : public Module
// here we perform access checks, this is the important bit that actually stops kicking/deopping
// etc of protected users. There are many types of access check, we're going to handle
// a relatively small number of them relevent to our module using a switch statement.
-
- ServerInstance->Log(DEBUG,"chanprotect OnAccessCheck %d",access_type);
// don't allow action if:
// (A) Theyre founder (no matter what)
// (B) Theyre protected, and you're not
@@ -397,10 +392,7 @@ class ModuleChanProtect : public Module
// firstly, if a ulined nick, or a server, is setting the mode, then allow them to set the mode
// without any access checks, we're not worthy :p
if ((ServerInstance->ULine(source->nick)) || (ServerInstance->ULine(source->server)) || (!*source->server))
- {
- ServerInstance->Log(DEBUG,"chanprotect OnAccessCheck returns ALLOW");
return ACR_ALLOW;
- }
std::string founder = "cm_founder_"+std::string(channel->name);
std::string protect = "cm_protect_"+std::string(channel->name);
@@ -409,17 +401,11 @@ class ModuleChanProtect : public Module
{
// a user has been deopped. Do we let them? hmmm...
case AC_DEOP:
- ServerInstance->Log(DEBUG,"OnAccessCheck AC_DEOP");
if (dest->GetExt(founder,dummyptr))
{
- ServerInstance->Log(DEBUG,"Has %s",founder.c_str());
source->WriteServ("484 "+std::string(source->nick)+" "+std::string(channel->name)+" :Can't deop "+std::string(dest->nick)+" as they're a channel founder");
return ACR_DENY;
}
- else
- {
- ServerInstance->Log(DEBUG,"Doesnt have %s",founder.c_str());
- }
if ((dest->GetExt(protect,dummyptr)) && (!source->GetExt(protect,dummyptr)))
{
source->WriteServ("484 "+std::string(source->nick)+" "+std::string(channel->name)+" :Can't deop "+std::string(dest->nick)+" as they're protected (+a)");
@@ -429,7 +415,6 @@ class ModuleChanProtect : public Module
// a user is being kicked. do we chop off the end of the army boot?
case AC_KICK:
- ServerInstance->Log(DEBUG,"OnAccessCheck AC_KICK");
if (dest->GetExt(founder,dummyptr))
{
source->WriteServ("484 "+std::string(source->nick)+" "+std::string(channel->name)+" :Can't kick "+std::string(dest->nick)+" as they're a channel founder");
@@ -472,7 +457,6 @@ class ModuleChanProtect : public Module
}
// we dont know what this access check is, or dont care. just carry on, nothing to see here.
- ServerInstance->Log(DEBUG,"chanprotect OnAccessCheck returns DEFAULT");
return ACR_DEFAULT;
}
diff --git a/src/modules/m_conn_umodes.cpp b/src/modules/m_conn_umodes.cpp
index 1b6bbe66d..2226f9776 100644
--- a/src/modules/m_conn_umodes.cpp
+++ b/src/modules/m_conn_umodes.cpp
@@ -61,13 +61,11 @@ class ModuleModesOnConnect : public Module
if (!IS_LOCAL(user))
return;
- ServerInstance->Log(DEBUG,"Post connect for mode setting");
for (int j = 0; j < Conf->Enumerate("connect"); j++)
{
std::string hostn = Conf->ReadValue("connect","allow",j);
if ((match(user->GetIPString(),hostn.c_str(),true)) || (match(user->host,hostn.c_str())))
{
- ServerInstance->Log(DEBUG,"Found matching connect block '%s'",hostn.c_str());
std::string ThisModes = Conf->ReadValue("connect","modes",j);
if (ThisModes != "")
{
@@ -96,7 +94,6 @@ class ModuleModesOnConnect : public Module
}
}
- ServerInstance->Log(DEBUG,"Call mode handler to set modes");
ServerInstance->Parser->CallHandler("MODE", modes, size, user);
}
break;
diff --git a/src/modules/m_opermodes.cpp b/src/modules/m_opermodes.cpp
index dbc34bcb5..57eb8ae23 100644
--- a/src/modules/m_opermodes.cpp
+++ b/src/modules/m_opermodes.cpp
@@ -93,7 +93,6 @@ class ModuleModesOnOper : public Module
for (unsigned int k = 1; k < tokens.size(); k++)
{
modes[i] = (char*)tokens[k].c_str();
- ServerInstance->Log(DEBUG, "m_opermodes.so: got mode param: %s", modes[i]);
i++;
}
}
@@ -106,7 +105,6 @@ class ModuleModesOnOper : public Module
n.push_back(modes[j]);
}
rmode.Send(ServerInstance);
- ServerInstance->Log(DEBUG, "m_opermodes.so: new modes for %s: %s", modes[0], modes[1]);
ServerInstance->SendMode(modes, size, user);
}
break;
diff --git a/src/modules/m_override.cpp b/src/modules/m_override.cpp
index d86f87b2a..e68d3f760 100644
--- a/src/modules/m_override.cpp
+++ b/src/modules/m_override.cpp
@@ -131,7 +131,6 @@ class ModuleOverride : public Module
switch (access_type)
{
case AC_DEOP:
- ServerInstance->Log(DEBUG,"Override access check AC_DEOP");
if (CanOverride(source,"MODEDEOP"))
{
if (NoisyOverride)
@@ -145,7 +144,6 @@ class ModuleOverride : public Module
}
break;
case AC_OP:
- ServerInstance->Log(DEBUG,"Override access check AC_OP");
if (CanOverride(source,"MODEOP"))
{
if (NoisyOverride)
@@ -159,7 +157,6 @@ class ModuleOverride : public Module
}
break;
case AC_VOICE:
- ServerInstance->Log(DEBUG,"Override access check AC_VOICE");
if (CanOverride(source,"MODEVOICE"))
{
if (NoisyOverride)
@@ -173,7 +170,6 @@ class ModuleOverride : public Module
}
break;
case AC_DEVOICE:
- ServerInstance->Log(DEBUG,"Override access check AC_DEVOICE");
if (CanOverride(source,"MODEDEVOICE"))
{
if (NoisyOverride)
@@ -187,7 +183,6 @@ class ModuleOverride : public Module
}
break;
case AC_HALFOP:
- ServerInstance->Log(DEBUG,"Override access check AC_HALFOP");
if (CanOverride(source,"MODEHALFOP"))
{
if (NoisyOverride)
@@ -201,7 +196,6 @@ class ModuleOverride : public Module
}
break;
case AC_DEHALFOP:
- ServerInstance->Log(DEBUG,"Override access check AC_DEHALFOP");
if (CanOverride(source,"MODEDEHALFOP"))
{
if (NoisyOverride)
@@ -221,7 +215,6 @@ class ModuleOverride : public Module
if (NoisyOverride)
if ((!channel->HasUser(source)) || (mode < STATUS_OP))
{
- ServerInstance->Log(DEBUG,"Overridden mode");
OverriddenMode = true;
OverOps = OverDeops = OverVoices = OverDevoices = OverHalfops = OverDehalfops = 0;
}