diff options
Diffstat (limited to 'src/worker_util.c')
-rw-r--r-- | src/worker_util.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/worker_util.c b/src/worker_util.c index ba4444485..976fe58c3 100644 --- a/src/worker_util.c +++ b/src/worker_util.c @@ -52,7 +52,9 @@ construct_task (struct rspamd_worker *worker) new_task->worker = worker; new_task->state = READ_COMMAND; - new_task->cfg = worker->srv->cfg; + if (worker) { + new_task->cfg = worker->srv->cfg; + } new_task->view_checked = FALSE; #ifdef HAVE_CLOCK_GETTIME # ifdef HAVE_CLOCK_PROCESS_CPUTIME_ID |