diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-07-28 15:09:52 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-07-28 15:09:52 +0100 |
commit | 4d6ff942ea5236dc0099e86db01eddfb3c0a121a (patch) | |
tree | 5532ddf3706b2c016e40f774c9cd3d5410111ada /src/libstat | |
parent | 799279700827221d7d5d0c67fe9ee29a5ed944f6 (diff) | |
download | rspamd-4d6ff942ea5236dc0099e86db01eddfb3c0a121a.tar.gz rspamd-4d6ff942ea5236dc0099e86db01eddfb3c0a121a.zip |
Do not add too many tokens from headers.
Diffstat (limited to 'src/libstat')
-rw-r--r-- | src/libstat/stat_process.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libstat/stat_process.c b/src/libstat/stat_process.c index a04c2536e..a3f8d8a73 100644 --- a/src/libstat/stat_process.c +++ b/src/libstat/stat_process.c @@ -57,16 +57,16 @@ rspamd_stat_tokenize_header (struct rspamd_task *task, if (rh != NULL) { LL_FOREACH (rh, cur) { - if (cur->value != NULL) { - str.begin = cur->value; - str.len = strlen (cur->value); - g_array_append_val (ar, str); - } if (cur->decoded != NULL) { str.begin = cur->decoded; str.len = strlen (cur->decoded); g_array_append_val (ar, str); } + else if (cur->value != NULL) { + str.begin = cur->value; + str.len = strlen (cur->value); + g_array_append_val (ar, str); + } } } } |