]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
Improve logging for fuzzy process errors.
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 12 May 2014 13:51:58 +0000 (14:51 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 12 May 2014 13:51:58 +0000 (14:51 +0100)
src/plugins/fuzzy_check.c

index 146450528cc15b6abdfd506dad91a45b6ed41311..1ee1013e640dc6d4cbb4c303e5a46c7cb7b054f1 100644 (file)
@@ -988,7 +988,7 @@ fuzzy_process_handler (struct rspamd_http_connection_entry *conn_ent,
        err = rspamd_mempool_alloc0 (task->task_pool, sizeof (GError *));
        r = process_message (task);
        if (r == -1) {
-               msg_warn ("processing of message failed");
+               msg_warn ("cannot process message for fuzzy");
                rspamd_task_free (task, FALSE);
                rspamd_controller_send_error (conn_ent, 400, "Message processing error");
                return;
@@ -1022,13 +1022,13 @@ fuzzy_process_handler (struct rspamd_http_connection_entry *conn_ent,
        }
 
        if (res == -1) {
-               msg_warn ("processing of message failed");
+               msg_warn ("cannot send fuzzy request: %s", strerror (errno));
                rspamd_task_free (task, FALSE);
                rspamd_controller_send_error (conn_ent, 400, "Message sending error");
                return;
        }
        else if (!processed) {
-               msg_warn ("processing of message failed");
+               msg_warn ("no rules to match fuzzy with flag %d", flag);
                rspamd_task_free (task, FALSE);
                rspamd_controller_send_error (conn_ent, 404, "No fuzzy rules matched");
                return;