From f25b4376911ab2f92e7990b59f032af58cb3da19 Mon Sep 17 00:00:00 2001 From: "Naram Qashat cyberbotx@cyberbotx.com" Date: Mon, 13 Oct 2008 23:13:41 +0000 Subject: [PATCH] Added listmax directive to chanserv block in new config. git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1441 5417fbe8-f217-4b02-8779-1006273d7864 --- data/example_new.conf | 5 +++++ src/config.c | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/data/example_new.conf b/data/example_new.conf index 0e46b85e5..7cc2cdb0c 100644 --- a/data/example_new.conf +++ b/data/example_new.conf @@ -416,4 +416,9 @@ chanserv * Limits the use of the ChanServ LIST command to IRC operators. This directive is optional. */ #listopersonly = yes + + /* + * The maximum number of channels to be returned for a ChanServ LIST command. + */ + listmax = 50 } diff --git a/src/config.c b/src/config.c index bb9fb1d1d..983fd16fa 100644 --- a/src/config.c +++ b/src/config.c @@ -591,6 +591,7 @@ int ServerConfig::Read(bool bail) {"chanserv", "autokickreason", "User has been banned from the channel", new ValueContainerChar(&CSAutokickReason), DT_CHARPTR, ValidateNotEmpty}, {"chanserv", "inhabit", "0", new ValueContainerTime(&CSInhabit), DT_TIME, ValidateNotZero}, {"chanserv", "listopersonly", "no", new ValueContainerBool(&CSListOpersOnly), DT_BOOLEAN, NoValidation}, + {"chanserv", "listmax", "0", new ValueContainerInt(&CSListMax), DT_INTEGER, ValidateNotZero}, {NULL, NULL, NULL, NULL, DT_NOTHING, NoValidation} }; /* These tags can occur multiple times, and therefore they have special code to read them @@ -1192,7 +1193,6 @@ Directive directives[] = { {"HostServName", {{PARAM_STRING, 0, &s_HostServ}, {PARAM_STRING, 0, &desc_HostServ}}}, {"ChanCoreModules", {{PARAM_STRING, PARAM_RELOAD, &ChanCoreModules}}}, - {"CSListMax", {{PARAM_POSINT, PARAM_RELOAD, &CSListMax}}}, {"CSRestrictGetPass", {{PARAM_SET, PARAM_RELOAD, &CSRestrictGetPass}}}, {"CSOpersOnly", {{PARAM_SET, PARAM_RELOAD, &CSOpersOnly}}}, {"DefSessionLimit", {{PARAM_POSINT, 0, &DefSessionLimit}}}, @@ -1692,7 +1692,6 @@ int read_config(int reload) CHECK(ReadTimeout); CHECK(WarningTimeout); CHECK(TimeoutCheck); - CHECK(CSListMax); CHECK(ServicesRoot); CHECK(AutokillExpiry); CHECK(ChankillExpiry);