aboutsummaryrefslogtreecommitdiffstats
path: root/src/libstat/stat_process.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2016-09-14 10:55:08 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2016-09-14 10:55:08 +0100
commit859480b9479c401f6ce14acbb45eb32f494b1a4e (patch)
tree150b239a79ecdf6ca64e8cf91d8497e9dbbaadf9 /src/libstat/stat_process.c
parentf733c89e9297cff3dcaea5b02eeaa5eb3a640b94 (diff)
downloadrspamd-859480b9479c401f6ce14acbb45eb32f494b1a4e.tar.gz
rspamd-859480b9479c401f6ce14acbb45eb32f494b1a4e.zip
[Minor] Use mime recipients count as a metatoken
Diffstat (limited to 'src/libstat/stat_process.c')
-rw-r--r--src/libstat/stat_process.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstat/stat_process.c b/src/libstat/stat_process.c
index 71983f10f..388d6b4e3 100644
--- a/src/libstat/stat_process.c
+++ b/src/libstat/stat_process.c
@@ -171,9 +171,9 @@ rspamd_stat_tokenize_parts_metadata (struct rspamd_stat_ctx *st_ctx,
g_array_append_val (ar, elt);
}
/* Number recipients */
- if (task->rcpt_envelope && task->rcpt_envelope->len > 0) {
+ if (task->rcpt_mime && internet_address_list_length (task->rcpt_mime) > 0) {
rspamd_snprintf (tmpbuf, sizeof (tmpbuf), "recipients%d",
- task->rcpt_envelope->len);
+ (gint)internet_address_list_length (task->rcpt_mime));
elt.begin = rspamd_mempool_strdup (task->task_pool, tmpbuf);
elt.len = strlen (elt.begin);
g_array_append_val (ar, elt);