]> jfr.im git - solanum.git/blobdiff - modules/m_rehash.c
Allow /rehash throttles to clear throttling.
[solanum.git] / modules / m_rehash.c
index 22848a8c94fd289bc0659d3236a39185efff64bb..4eb4add92b387e196ba85cc35211b9bca0d5e912 100644 (file)
@@ -212,6 +212,15 @@ rehash_rejectcache(struct Client *source_p)
 
 }
 
+static void
+rehash_throttles(struct Client *source_p)
+{
+       sendto_realops_snomask(SNO_GENERAL, L_ALL, "%s is clearing throttles",
+                               get_oper_name(source_p));
+       flush_throttle();
+
+}
+
 static void
 rehash_help(struct Client *source_p)
 {
@@ -252,6 +261,7 @@ static struct hash_commands rehash_commands[] =
        {"TXLINES",     rehash_txlines          },
        {"TRESVS",      rehash_tresvs           },
        {"REJECTCACHE", rehash_rejectcache      },
+       {"THROTTLES",   rehash_throttles        },
        {"HELP",        rehash_help             },
        {"NICKDELAY",   rehash_nickdelay        },
        {NULL,          NULL                    }