diff options
author | Matt A. Tobin <email@mattatobin.com> | 2019-11-11 00:54:45 -0500 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2019-11-11 00:54:45 -0500 |
commit | 0903ef35611c8d2a966f057d2e74437a73de71df (patch) | |
tree | 86887ecd9e09a790dc74188f98a24b7d36863246 | |
parent | bca2de131b9a931f612435d8e50864ebcb7519f8 (diff) | |
download | UXP-0903ef35611c8d2a966f057d2e74437a73de71df.tar UXP-0903ef35611c8d2a966f057d2e74437a73de71df.tar.gz UXP-0903ef35611c8d2a966f057d2e74437a73de71df.tar.lz UXP-0903ef35611c8d2a966f057d2e74437a73de71df.tar.xz UXP-0903ef35611c8d2a966f057d2e74437a73de71df.zip |
Bug 1167982 - Do charset detection for all text/* attachments in composition, not just text/plain.
Tag #1273
-rw-r--r-- | mailnews/compose/src/nsMsgAttachmentHandler.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mailnews/compose/src/nsMsgAttachmentHandler.cpp b/mailnews/compose/src/nsMsgAttachmentHandler.cpp index 0ae253ed6..9555de37f 100644 --- a/mailnews/compose/src/nsMsgAttachmentHandler.cpp +++ b/mailnews/compose/src/nsMsgAttachmentHandler.cpp @@ -522,7 +522,9 @@ DONE: nsresult nsMsgAttachmentHandler::PickCharset() { - if (!m_charset.IsEmpty() || !m_type.LowerCaseEqualsLiteral(TEXT_PLAIN)) + if (!m_charset.IsEmpty() || + !StringBeginsWith(m_type, NS_LITERAL_CSTRING("text/"), + nsCaseInsensitiveCStringComparator())) return NS_OK; nsCOMPtr<nsIFile> tmpFile = |