]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Mime: Fix processing of attached messages
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 22 Jan 2019 12:36:06 +0000 (12:36 +0000)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 22 Jan 2019 12:36:06 +0000 (12:36 +0000)
src/libmime/mime_parser.c

index 4439d055e582a26d635871d6e7bd9d6230bbc679..82a0cbafbc523514eed2b0b3f3973ef453f37a29 100644 (file)
@@ -1214,14 +1214,14 @@ rspamd_mime_parse_message (struct rspamd_task *task,
                                                npart->raw_headers_len,
                                                FALSE);
                        }
-               }
-               else {
-                       body_pos = 0;
 
                        hdrs = rspamd_message_get_header_from_hash (npart->raw_headers,
                                        task->task_pool,
                                        "Content-Type", FALSE);
                }
+               else {
+                       body_pos = 0;
+               }
 
                pbegin = part->parsed_data.begin + body_pos;
                plen = part->parsed_data.len - body_pos;