len = task->from_envelope->addr_len;
}
- msg_info_task_encrypted ("<%s> %s: %*s; ip: %s; URL: %*s",
+ msg_notice_task_encrypted ("<%s> %s: %*s; ip: %s; URL: %*s",
task->message_id,
has_user ? "user" : "from",
len, user_field,
if (task->cfg->log_flags & RSPAMD_LOG_FLAG_RE_CACHE) {
restat = rspamd_re_cache_get_stat (task->re_rt);
g_assert (restat != NULL);
- msg_info_task (
+ msg_notice_task (
"regexp statistics: %ud pcre regexps scanned, %ud regexps matched,"
" %ud regexps total, %ud regexps cached,"
" %HL bytes scanned using pcre, %HL bytes scanned total",
}
}
- msg_info_task ("%V", logbuf);
+ msg_notice_task ("%V", logbuf);
rspamd_fstring_free (logbuf);
}
cptype = g_quark_to_string (rspamd_log->process_type);
if (rspamd_log->flags & RSPAMD_LOG_FLAG_COLOR) {
- if (level_flags & G_LOG_LEVEL_INFO) {
+ if (level_flags & (G_LOG_LEVEL_INFO|G_LOG_LEVEL_MESSAGE)) {
/* White */
r = rspamd_snprintf (tmpbuf, sizeof (tmpbuf), "\033[0;37m");
}
mlen = strlen (message);
if (rspamd_log->flags & RSPAMD_LOG_FLAG_COLOR) {
- if (level_flags & G_LOG_LEVEL_INFO) {
+ if (level_flags & (G_LOG_LEVEL_INFO|G_LOG_LEVEL_MESSAGE)) {
/* White */
r = rspamd_snprintf (tmpbuf, sizeof (tmpbuf), "\033[0;37m");
}
task->task_pool->tag.tagname, task->task_pool->tag.uid, \
G_STRFUNC, \
__VA_ARGS__)
+#define msg_notice_task_encrypted(...) rspamd_default_log_function (G_LOG_LEVEL_MESSAGE|RSPAMD_LOG_ENCRYPTED, \
+ task->task_pool->tag.tagname, task->task_pool->tag.uid, \
+ G_STRFUNC, \
+ __VA_ARGS__)
#define msg_info_task_encrypted(...) rspamd_default_log_function (G_LOG_LEVEL_INFO|RSPAMD_LOG_ENCRYPTED, \
task->task_pool->tag.tagname, task->task_pool->tag.uid, \
G_STRFUNC, \
task ? task->task_pool->tag.tagname : NULL, task ? task->task_pool->tag.uid : NULL, \
G_STRFUNC, \
__VA_ARGS__)
-#define msg_info_task_check(...) rspamd_default_log_function (G_LOG_LEVEL_INFO, \
+#define msg_info_task_check(...) rspamd_default_log_function (G_LOG_LEVEL_MESSAGE, \
+ task ? task->task_pool->tag.tagname : NULL, task ? task->task_pool->tag.uid : NULL, \
+ G_STRFUNC, \
+ __VA_ARGS__)
+#define msg_notice_task_check(...) rspamd_default_log_function (G_LOG_LEVEL_INFO, \
task ? task->task_pool->tag.tagname : NULL, task ? task->task_pool->tag.uid : NULL, \
G_STRFUNC, \
__VA_ARGS__)