md5 for text/plain attachments was not computed, stayed same as parent so they were not shown if hide duplicates option was active in the GUI
This commit is contained in:
parent
7048d2a014
commit
7b8ba96b25
@ -260,8 +260,8 @@ bool MimeHandlerMail::processAttach()
|
|||||||
att->m_charset << "] fn [" << att->m_filename << "]\n");
|
att->m_charset << "] fn [" << att->m_filename << "]\n");
|
||||||
|
|
||||||
// Erase current content and replace
|
// Erase current content and replace
|
||||||
m_metaData[cstr_dj_keycontent] = string();
|
|
||||||
string& body = m_metaData[cstr_dj_keycontent];
|
string& body = m_metaData[cstr_dj_keycontent];
|
||||||
|
body.clear();
|
||||||
att->m_part->getBody(body, 0, att->m_part->bodylength);
|
att->m_part->getBody(body, 0, att->m_part->bodylength);
|
||||||
{
|
{
|
||||||
string decoded;
|
string decoded;
|
||||||
@ -285,10 +285,15 @@ bool MimeHandlerMail::processAttach()
|
|||||||
|
|
||||||
// Special case for text/plain content. Internfile should deal
|
// Special case for text/plain content. Internfile should deal
|
||||||
// with this but it expects text/plain to be utf-8 already, so we
|
// with this but it expects text/plain to be utf-8 already, so we
|
||||||
// handle the transcoding if needed
|
// handle the transcoding if needed. Same kind of issue for the MD5
|
||||||
if (m_metaData[cstr_dj_keymt] == cstr_textplain) {
|
if (m_metaData[cstr_dj_keymt] == cstr_textplain) {
|
||||||
if (!txtdcode("MimeHandlerMail::processAttach"))
|
if (!txtdcode("MimeHandlerMail::processAttach")) {
|
||||||
body.clear();
|
body.clear();
|
||||||
|
} else if (!m_forPreview) {
|
||||||
|
string md5, xmd5;
|
||||||
|
MD5String(body, md5);
|
||||||
|
m_metaData[cstr_dj_keymd5] = MD5HexPrint(md5, xmd5);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Ipath
|
// Ipath
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user