aboutsummaryrefslogtreecommitdiffstats
path: root/src/message.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rambler-co.ru>2011-03-04 19:38:04 +0300
committerVsevolod Stakhov <vsevolod@rambler-co.ru>2011-03-04 19:38:04 +0300
commitde9ac8f1938e09f3c6c3d6f261db4749b3b9ff01 (patch)
treeea861fa0702a4dd3103de7c24ebd164b4aa21855 /src/message.c
parent2a2bc886c1b43a9c43a812959d7193cc03d7bc8d (diff)
downloadrspamd-de9ac8f1938e09f3c6c3d6f261db4749b3b9ff01.tar.gz
rspamd-de9ac8f1938e09f3c6c3d6f261db4749b3b9ff01.zip
* Add multimaps for "FROM" and "TO" headers (mime an smtp data can be checked)
* Improve lua api for getting message's sender and recipients
Diffstat (limited to 'src/message.c')
-rw-r--r--src/message.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/message.c b/src/message.c
index 86e333dc1..80711b791 100644
--- a/src/message.c
+++ b/src/message.c
@@ -1113,7 +1113,9 @@ enum {
HEADER_UNKNOWN
};
-
+/*
+ * Iterate throught all headers and make a list
+ */
#ifndef GMIME24
static void
header_iterate (memory_pool_t * pool, struct gmime_raw_header *h, GList ** ret, const gchar *field, gboolean strong)
@@ -1146,6 +1148,7 @@ header_iterate (memory_pool_t * pool, struct gmime_raw_header *h, GList ** ret,
static void
header_iterate (memory_pool_t * pool, GMimeHeaderList * ls, GList ** ret, const gchar *field, gboolean strong)
{
+ /* Use iterator in case of gmime 2.4 */
GMimeHeaderIter *iter;
const gchar *name;
@@ -1156,6 +1159,7 @@ header_iterate (memory_pool_t * pool, GMimeHeaderList * ls, GList ** ret, const
iter = g_mime_header_iter_new ();
if (g_mime_header_list_get_iter (ls, iter) && g_mime_header_iter_first (iter)) {
+ /* Iterate throught headers */
while (g_mime_header_iter_is_valid (iter)) {
name = g_mime_header_iter_get_name (iter);
if (G_LIKELY (!strong)) {