Commit 6a451425 authored by Sandro Knauß's avatar Sandro Knauß

fix crashes with not TextMessageParts, that should be hidden.

parent bc5a86e3
......@@ -852,8 +852,8 @@ void DefaultRendererPrivate::renderFactory(const MessagePart::Ptr &msgPart, Html
if (isHiddenHint(msgPart)) {
QByteArray cid = msgPart->content()->contentID()->identifier();
if (!cid.isEmpty()) {
auto mp = msgPart.dynamicCast<MimeTreeParser::TextMessagePart>();
auto mp = msgPart.dynamicCast<MimeTreeParser::TextMessagePart>();
if (!cid.isEmpty() && mp) {
QString fileName = mp->temporaryFilePath();
QString href = QUrl::fromLocalFile(fileName).url();
htmlWriter->embedPart(cid, href);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment