diff options
-rw-r--r-- | src/libmime/content_type.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/libmime/content_type.c b/src/libmime/content_type.c index 9161850c9..fa9768bf4 100644 --- a/src/libmime/content_type.c +++ b/src/libmime/content_type.c @@ -50,6 +50,15 @@ rspamd_content_type_add_param (rspamd_mempool_t *pool, if (!found) { g_hash_table_insert (ct->attrs, &nparam->name, nparam); } + + srch.begin = "charset"; + srch.len = 7; + + if (rspamd_ftok_cmp (&nparam->name, &srch) == 0) { + /* Adjust charset */ + ct->charset.begin = nparam->value.begin; + ct->charset.len = nparam->value.len; + } } struct rspamd_content_type * |