summaryrefslogtreecommitdiffstats
path: root/src/worker.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2013-09-11 13:15:59 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2013-09-11 13:15:59 +0100
commitcfaddb2c383a9066f8105245f3459cc1e8ff87d1 (patch)
tree566655281d95622ae2f426d6d4e07ae09fc830b3 /src/worker.c
parentd218a287788d3040ce5b31e2904641c69c7f49b9 (diff)
downloadrspamd-cfaddb2c383a9066f8105245f3459cc1e8ff87d1.tar.gz
rspamd-cfaddb2c383a9066f8105245f3459cc1e8ff87d1.zip
Another try to fix skipped messages.
Diffstat (limited to 'src/worker.c')
-rw-r--r--src/worker.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/worker.c b/src/worker.c
index 6974c8018..f27c6c2a9 100644
--- a/src/worker.c
+++ b/src/worker.c
@@ -389,6 +389,10 @@ read_socket (f_str_t * in, void *arg)
remove_async_thread (task->s);
}
}
+ if (task->is_skipped) {
+ /* Call write_socket to write reply and exit */
+ return write_socket (task);
+ }
}
else {
lua_call_pre_filters (task);
@@ -475,7 +479,7 @@ write_socket (void *arg)
return write_socket (task);
}
/* Add task to classify to classify pool */
- if (ctx->classify_pool) {
+ if (!task->is_skipped && ctx->classify_pool) {
register_async_thread (task->s);
g_thread_pool_push (ctx->classify_pool, task, &err);
if (err != NULL) {
@@ -483,6 +487,10 @@ write_socket (void *arg)
remove_async_thread (task->s);
}
}
+ if (task->is_skipped) {
+ /* Call write_socket again to write reply and exit */
+ return write_socket (task);
+ }
break;
default:
msg_info ("abnormally closing connection at state: %d", task->state);