From c8b61e0e1f69d60751b6c62f69e13e6e705c1540 Mon Sep 17 00:00:00 2001 From: Sven Strickroth Date: Fri, 19 Jun 2015 14:03:13 +0200 Subject: [PATCH] Fixed issue #2504: Problems with MS Outlook and generated emails Signed-off-by: Sven Strickroth --- src/Changelog.txt | 1 + src/Utils/MailMsg.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/Changelog.txt b/src/Changelog.txt index 802201ad7..41ebb9b86 100644 --- a/src/Changelog.txt +++ b/src/Changelog.txt @@ -17,6 +17,7 @@ Released: unreleased * Fixed issue #2514: diff uses wrong tool in case the filename matches a registered extension * Fixed issue #2487: Show log dialog lose focus of "working dir changes" after content refresh * Fixed issue #2517: Submodule Update dialog cannot be re-sized and is too small to be useful in some cases + * Fixed issue #2504: Problems with MS Outlook and generated emails = Release 1.8.14.0 = Released: 2015-04-08 diff --git a/src/Utils/MailMsg.cpp b/src/Utils/MailMsg.cpp index a015f6939..20a71e85f 100644 --- a/src/Utils/MailMsg.cpp +++ b/src/Utils/MailMsg.cpp @@ -68,7 +68,7 @@ CMailMsg::~CMailMsg() void CMailMsg::SetFrom(const CString& sAddress, const CString& sName) { - m_from = CUnicodeUtils::GetUTF8(sAddress); + m_from = CUnicodeUtils::GetUTF8(L"SMTP:" + sAddress); m_fromname = CUnicodeUtils::GetUTF8(sName); } @@ -81,7 +81,7 @@ static void addAdresses(std::vector& recipients, const CString& sAd address = address.Trim(); if (address.IsEmpty()) continue; - recipients.push_back((std::string)CUnicodeUtils::GetUTF8(address)); + recipients.push_back((std::string)CUnicodeUtils::GetUTF8(L"SMTP:" + address)); } } @@ -257,7 +257,7 @@ BOOL CMailMsg::Send() pRecipients[nIndex].ulReserved = 0; pRecipients[nIndex].ulRecipClass = MAPI_TO; pRecipients[nIndex].lpszAddress = (LPSTR)m_to.at(i).c_str(); - pRecipients[nIndex].lpszName = (LPSTR)m_to.at(i).c_str(); + pRecipients[nIndex].lpszName = (LPSTR)m_to.at(i).c_str() + 5; pRecipients[nIndex].ulEIDSize = 0; pRecipients[nIndex].lpEntryID = NULL; } @@ -269,7 +269,7 @@ BOOL CMailMsg::Send() pRecipients[nIndex].ulReserved = 0; pRecipients[nIndex].ulRecipClass = MAPI_CC; pRecipients[nIndex].lpszAddress = (LPSTR)m_cc.at(i).c_str(); - pRecipients[nIndex].lpszName = (LPSTR)m_cc.at(i).c_str(); + pRecipients[nIndex].lpszName = (LPSTR)m_cc.at(i).c_str() + 5; pRecipients[nIndex].ulEIDSize = 0; pRecipients[nIndex].lpEntryID = NULL; } -- 2.11.4.GIT