summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--data/example_new.conf6
-rw-r--r--src/config.c6
2 files changed, 7 insertions, 5 deletions
diff --git a/data/example_new.conf b/data/example_new.conf
index 642f17066..d4a7e4c57 100644
--- a/data/example_new.conf
+++ b/data/example_new.conf
@@ -600,4 +600,10 @@ hostserv
* name) of the client.
*/
description = "vHost Service"
+
+ /*
+ * The filename of the HostServ database. The path is relative to the services
+ * executable. If not given, defaults to "hosts.db".
+ */
+ database = "hosts.db"
}
diff --git a/src/config.c b/src/config.c
index aef2e7473..2e1a2d26a 100644
--- a/src/config.c
+++ b/src/config.c
@@ -632,6 +632,7 @@ int ServerConfig::Read(bool bail)
{"botserv", "fantasycharacter", "!", new ValueContainerChar(&BSFantasyCharacter), DT_BOOLEAN, NoValidation},
{"hostserv", "nick", "", new ValueContainerChar(&s_HostServ), DT_CHARPTR, NoValidation},
{"hostserv", "description", "vHost Service", new ValueContainerChar(&desc_HostServ), DT_CHARPTR, ValidateHostServ},
+ {"hostserv", "database", "hosts.db", new ValueContainerChar(&HostDBName), DT_CHARPTR, ValidateHostServ},
{NULL, NULL, NULL, NULL, DT_NOTHING, NoValidation}
};
/* These tags can occur multiple times, and therefore they have special code to read them
@@ -1212,7 +1213,6 @@ Directive directives[] = {
{"BadPassLimit", {{PARAM_POSINT, PARAM_RELOAD, &BadPassLimit}}},
{"BadPassTimeout", {{PARAM_TIME, PARAM_RELOAD, &BadPassTimeout}}},
{"BotCoreModules", {{PARAM_STRING, PARAM_RELOAD, &BotCoreModules}}},
- {"HostServDB", {{PARAM_STRING, PARAM_RELOAD, &HostDBName}}},
{"ChanCoreModules", {{PARAM_STRING, PARAM_RELOAD, &ChanCoreModules}}},
{"DefSessionLimit", {{PARAM_POSINT, 0, &DefSessionLimit}}},
{"DisableRaw", {{PARAM_SET, PARAM_RELOAD, &DisableRaw}}},
@@ -1913,10 +1913,6 @@ int read_config(int reload)
}
}
- if (s_HostServ) {
- CHEK2(HostDBName, HostServDB);
- }
-
if (UseMail) {
CHECK(SendMailPath);
CHECK(SendFrom);