aboutsummaryrefslogtreecommitdiffstats
path: root/src/controller.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/controller.c')
-rw-r--r--src/controller.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/controller.c b/src/controller.c
index 36261674c..75a502871 100644
--- a/src/controller.c
+++ b/src/controller.c
@@ -3039,6 +3039,7 @@ start_controller_worker (struct rspamd_worker *worker)
ctx->start_time = time (NULL);
ctx->worker = worker;
ctx->cfg = worker->srv->cfg;
+ REF_RETAIN (ctx->cfg);
ctx->srv = worker->srv;
ctx->custom_commands = g_hash_table_new (rspamd_strcase_hash,
rspamd_strcase_equal);
@@ -3212,5 +3213,7 @@ start_controller_worker (struct rspamd_worker *worker)
munmap (m, ctx->cached_enable_password.len);
}
+ REF_RELEASE (ctx->cfg);
+
exit (EXIT_SUCCESS);
}