]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Fix error propagation
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Sat, 26 Oct 2019 19:02:33 +0000 (20:02 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Sat, 26 Oct 2019 19:09:02 +0000 (20:09 +0100)
src/libmime/mime_parser.c

index 21374e2495db8e876bae5dbcb5d8f7f3f734f8df..0b682879d170f07f0a95c92f24f5af2e2e368ca5 100644 (file)
@@ -1382,6 +1382,10 @@ rspamd_mime_parse_message (struct rspamd_task *task,
                ret = rspamd_mime_parse_normal_part (task, npart, nst, err);
        }
 
+       if (ret != RSPAMD_MIME_PARSE_OK) {
+               return ret;
+       }
+
        if (part && st->stack->len > 0) {
                /* Remove message part from the parent stack */
                g_ptr_array_remove_index_fast (st->stack, st->stack->len - 1);