diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2010-12-24 19:32:27 +0300 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2010-12-24 19:32:27 +0300 |
commit | 7de53fbf2d93398465c3a77c734d3005407fc4b5 (patch) | |
tree | ffd9608fd54018de084f5881941ab323f241e4df /src | |
parent | 7fee46879ec9c5a06b4e79bec691fea9d391857f (diff) | |
download | rspamd-7de53fbf2d93398465c3a77c734d3005407fc4b5.tar.gz rspamd-7de53fbf2d93398465c3a77c734d3005407fc4b5.zip |
Write client's host when network error is occured
Write domain name for redirectors call
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/surbl.c | 8 | ||||
-rw-r--r-- | src/worker.c | 3 |
2 files changed, 7 insertions, 4 deletions
diff --git a/src/plugins/surbl.c b/src/plugins/surbl.c index 840710b39..850c53766 100644 --- a/src/plugins/surbl.c +++ b/src/plugins/surbl.c @@ -886,7 +886,8 @@ redirector_callback (gint fd, short what, void *arg) static void -register_redirector_call (struct uri *url, struct worker_task *task, GTree * url_tree, struct suffix_item *suffix) +register_redirector_call (struct uri *url, struct worker_task *task, GTree * url_tree, + struct suffix_item *suffix, const gchar *rule) { gint s = -1; struct redirector_param *param; @@ -925,7 +926,8 @@ register_redirector_call (struct uri *url, struct worker_task *task, GTree * url event_add (¶m->ev, timeout); register_async_event (task->s, free_redirector_session, param, FALSE); - msg_info ("<%s> registered redirector call for %s to %s", task->message_id, struri (url), selected->name); + msg_info ("<%s> registered redirector call for %s to %s, according to rule: %s", + task->message_id, struri (url), selected->name, rule); } static gboolean @@ -958,7 +960,7 @@ surbl_tree_url_callback (gpointer key, gpointer value, void *data) re = g_hash_table_lookup (surbl_module_ctx->redirector_hosts, red_domain); if (re != NULL && (re == NO_REGEXP || g_regex_match (re, url->string, 0, NULL))) { /* If no regexp found or founded regexp matches url string register redirector's call */ - register_redirector_call (url, param->task, param->tree, param->suffix); + register_redirector_call (url, param->task, param->tree, param->suffix, red_domain); param->task->save.saved++; return FALSE; } diff --git a/src/worker.c b/src/worker.c index 39cf8fb81..160aa6969 100644 --- a/src/worker.c +++ b/src/worker.c @@ -446,7 +446,8 @@ err_socket (GError * err, void *arg) struct rspamd_worker_ctx *ctx; ctx = task->worker->ctx; - msg_info ("abnormally closing connection, error: %s", err->message); + + msg_info ("abnormally closing connection from: %s, error: %s", inet_ntoa (task->client_addr), err->message); /* Free buffers */ if (ctx->is_custom) { fin_custom_filters (task); |