]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Include some more information about archives
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 4 Jul 2016 15:46:20 +0000 (16:46 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 4 Jul 2016 15:46:20 +0000 (16:46 +0100)
src/libmime/archives.c
src/libmime/archives.h

index 2de9d7176be2e2d079da17471fc9f416ba43cb94..9a9d1da3ad764d585a8d651862551d349ffe5023 100644 (file)
@@ -141,6 +141,8 @@ rspamd_archive_process_zip (struct rspamd_task *task,
 
        part->flags |= RSPAMD_MIME_PART_ARCHIVE;
        part->specific_data = arch;
+       arch->archive_name = part->filename;
+       arch->size = part->content->len;
 }
 
 void
index 917a37a70b54aaf3fc16b60fc6b4689ed2b9025b..3e8c8a46c1734d30b596841b64954939f7b60282 100644 (file)
@@ -25,6 +25,8 @@ enum rspamd_archive_type {
 
 struct rspamd_archive {
        enum rspamd_archive_type type;
+       const gchar *archive_name;
+       gsize size;
        GPtrArray *files; /* Array of GStrings */
 };