From f11a1c737f7e1d524d8b8bc056a531ab0f669d8e Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Mon, 21 Sep 2009 18:46:48 +0400 Subject: * Add time out for sync IO as it can cause unpredictable errors --- src/plugins/regexp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/plugins') diff --git a/src/plugins/regexp.c b/src/plugins/regexp.c index dcbdce7b6..d8d9f3ea8 100644 --- a/src/plugins/regexp.c +++ b/src/plugins/regexp.c @@ -312,10 +312,10 @@ process_regexp (struct rspamd_regexp *re, struct worker_task *task) return 0; } else { + memory_pool_add_destructor (task->task_pool, (pool_destruct_func)g_list_free, headerlist); if (re->regexp == NULL) { msg_debug ("process_regexp: regexp contains only header and it is found %s", re->header); task_cache_add (task, re, 1); - g_list_free (headerlist); return 1; } cur = headerlist; @@ -327,7 +327,6 @@ process_regexp (struct rspamd_regexp *re, struct worker_task *task) } cur = g_list_next (cur); } - g_list_free (headerlist); task_cache_add (task, re, 0); return 0; } -- cgit v1.2.3