]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-storage: Don't try to deserialize bodystructure if we already have it
authorJosef 'Jeff' Sipek <jeff.sipek@dovecot.fi>
Fri, 7 Sep 2018 14:43:43 +0000 (10:43 -0400)
committerJosef 'Jeff' Sipek <jeff.sipek@dovecot.fi>
Fri, 7 Sep 2018 14:43:43 +0000 (10:43 -0400)
Fixes:
Panic: file message-part-data.c: line 37 (message_part_data_is_plain_7bit): assertion failed: (data != NULL)

src/lib-storage/index/index-mail.c

index 07b4dd0fdda0587509ea5f4b9a56cefab8c8a5e2..e850f6a7cf3db439348f314369a04fd6755b51b9 100644 (file)
@@ -131,6 +131,9 @@ static bool get_cached_parts(struct index_mail *mail)
 {
        struct message_part *part;
 
+       if (mail->data.parts != NULL)
+               return TRUE;
+
        T_BEGIN {
                part = get_unserialized_parts(mail);
        } T_END;