From 622f1d396f877388560e97ba2e4b197f23abd294 Mon Sep 17 00:00:00 2001 From: "cavin%netscape.com" Date: Fri, 31 May 2002 02:24:28 +0000 Subject: [PATCH] Fix for 145150. Map "Content-Type: application/ms-tnef" to "Content-Type: text/plain" so the body text can be displayed normally (instead of in an attachment). r=ducarroz, sr=bienvenu. --- mailnews/import/outlook/src/nsOutlookCompose.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mailnews/import/outlook/src/nsOutlookCompose.cpp b/mailnews/import/outlook/src/nsOutlookCompose.cpp index ca249fceb638..62a025392fd6 100644 --- a/mailnews/import/outlook/src/nsOutlookCompose.cpp +++ b/mailnews/import/outlook/src/nsOutlookCompose.cpp @@ -1030,6 +1030,10 @@ nsresult nsOutlookCompose::WriteHeaders( nsIFileSpec *pDst, SimpleBufferTonyRCop if ((specialHeader = IsSpecialHeader( header.get())) != -1) { header.Append( ':'); GetHeaderValue( newHeaders.m_pBuffer, newHeaders.m_writeOffset - 1, header.get(), val, PR_FALSE); + // Bug 145150 - Turn "Content-Type: application/ms-tnef" into "Content-Type: text/plain" + // so the body text can be displayed normally (instead of in an attachment). + if (!PL_strcasecmp(header.get(), "Content-Type:") && !PL_strcasecmp(val.get(), "application/ms-tnef")) + val.Assign("text/plain"); header.Truncate( header.Length() - 1); specials[specialHeader] = PR_TRUE; }