/*
* This module handles states which are global to the entire server.
*
- * Copyright (c) 1987-2020 by the citadel.org team
+ * Copyright (c) 1987-2021 by the citadel.org team
*
* This program is open source software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 3.
struct legacy_ctrl_format c;
memset(&c, 0, sizeof(c));
- fp = fopen(file_citadel_control, "rb+");
+ fp = fopen("citadel.control", "rb+");
if (fp != NULL) {
syslog(LOG_INFO, "control: legacy format record found -- importing to db");
fread(&c, sizeof(struct legacy_ctrl_format), 1, fp);
CtdlSetConfigLong( "MMfulltext", c.MMfulltext);
fclose(fp);
- if (unlink(file_citadel_control) != 0) {
- fprintf(stderr, "Unable to remove legacy control record %s after migrating it.\n", file_citadel_control);
+ if (unlink("citadel.control") != 0) {
+ fprintf(stderr, "Unable to remove legacy control record after migrating it.\n");
fprintf(stderr, "Exiting to prevent data corruption.\n");
exit(CTDLEXIT_CONFIG);
}
/* MODULE INITIALIZATION STUFF */
/*****************************************************************************/
-void control_cleanup(void)
-{
- DeleteHash(&CfgNameHash);
-}
CTDL_MODULE_INIT(control)
{
if (!threading) {
CtdlRegisterProtoHook(cmd_gvdn, "GVDN", "get valid domain names");
CtdlRegisterProtoHook(cmd_conf, "CONF", "get/set system configuration");
- CtdlRegisterCleanupHook(control_cleanup);
-
}
/* return our id for the Log */
return "control";