Closed
Bug 115096
Opened 23 years ago
Closed 22 years ago
In reply composition, RFC2047 encoded characters of Subject are mis-interpreted if not in charset of body
Categories
(MailNews Core :: MIME, defect)
MailNews Core
MIME
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: jmdesp, Assigned: nhottanscp)
References
Details
(Keywords: dataloss)
Attachments
(3 files, 1 obsolete file)
1.63 KB,
message/rfc822
|
Details | |
1.24 KB,
message/rfc822
|
Details | |
4.15 KB,
patch
|
sspitzer
:
review+
sspitzer
:
review+
mscott
:
superreview+
asa
:
approval1.4.1-
sspitzer
:
approval1.5b+
|
Details | Diff | Splinter Review |
There's a bit of i18n involved, but it more seems like a problem in MIME.
I read a news message with the header in ISO-8859-15 encoded after RFC2047,
but the body in ISO-8859-1.
Inside the content of the header, there's 6 Euro symbols.
When answering the message, in the title of the message in the composing
windows, the 6 Euro symbols are replaced by 6 neutral monetary symbol.
If I then send the message, it's sent in ISO-8859-1, header and content, and the
title has the 6 Euro replaced by 6 neutral monetary symbols.
The main difference between ISO-8859-1 and ISO-8859-15 is that the code
point that was neutral monetary symbol in ISO-8859-1 is now the Euro
symbol in ISO-8859-15.
It sounds like when the data inside the title is decoded, it is not
tagged as being ISO-8859-15, and gets converted to unicode using the
charset of the body instead of using the charset that was inside the
RFC2047 encoding.
I join the original message as an attachment.
Reporter | ||
Comment 1•23 years ago
|
||
Reporter | ||
Comment 2•23 years ago
|
||
Setting the default encoding of the folder to ISO-8859-15 instead of ISO-8859-1
changes nothing to the problem.
Comment 3•23 years ago
|
||
I see it in Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9+) Gecko/20020426.
pi
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows NT → All
Hardware: PC → All
Assignee | ||
Comment 5•23 years ago
|
||
For reply, the charset of the original mail body is used for both header and body.
But I think this is fixed by bug 109342 because it implemented a fallback
mechanism for charset conversion failure.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Reporter | ||
Comment 6•22 years ago
|
||
Reopening. This is still not corrected in 2003012908.
Reproduction Steps :
- Open message in mailer
- The title has 6 euro symbols
- Create a reply (CTRL-R)
- The title in the message composition windows has 6 neutral monetary symbol
The original sample was using euro characters, so it looked like it was a euro
problem. In fact, it has nothing to see with Euro.
I have a new sample of the problem, that has in the subject :
Subject: Re: Raw UTF8 - =?windows-1251?Q?=CA=E8=F0=E8=EB=EB=E8=F6=E0?=
and a content type of :
Content-Type: text/plain; charset=us-ascii; format=flowed
With the reproduction step before the title is initially :
Re: Raw UTF8 - Кириллица
And in the reply composition window, the title is changed to :
Re: Raw UTF8 - Кириллица
The charset of the original data was windows-1251, but in the title of the reply
composition windows, it is interpreted as if it were something else.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Summary: RFC2047 encode characters in Subject header are interpreted in the charset of the body → In reply composition, RFC2047 encoded characters of Subject are mis-interpreted if not in charset of body
Reporter | ||
Comment 7•22 years ago
|
||
Comment 8•22 years ago
|
||
I can confirm - not only for UTF. Every time, when mail body and subject have
differnt charsets, making reply converts subect as string with charset like in
mail body.
If subject is russian (koi80r, or windows-1251), message body is 8859-1 then
subject converts to the junk.
Comment 9•22 years ago
|
||
*** Bug 191885 has been marked as a duplicate of this bug. ***
Comment 10•22 years ago
|
||
This bug means, data is lost (namely all the information in the subject of the
reply). Setting keyword. Dataloss by definition is critical.
This bug really is bad for MailNews. Such an important release as upcoming 1.4
must not have it. Requesting blocking.
pi
Comment 12•22 years ago
|
||
This is very elementary MIME functionality. Asking for new blocking.
pi
Flags: blocking1.5b?
Flags: blocking1.4.x?
Comment 13•22 years ago
|
||
bienvenu or sspitzer, can one of you take a look at this and see if there's a
quick fix we could get for beta?
Comment 14•22 years ago
|
||
well, one possibility would be to use nsIMsgHdr::GetMime2DecodedSubject, which
is what the view code does, and that seems to work. Not sure why because the
code looks very similar. I'd have to step through to see what's different.
Comment 15•22 years ago
|
||
using GetMime2DecodedSubject seems to fix the problem and cleans up the code a
bit.
Comment 16•22 years ago
|
||
whoops, don't need the reply on top sig quoting stuff.
Attachment #129381 -
Attachment is obsolete: true
Updated•22 years ago
|
Attachment #129382 -
Flags: superreview?(scott)
Updated•22 years ago
|
Attachment #129382 -
Flags: superreview?(scott) → superreview+
Comment 17•22 years ago
|
||
Comment on attachment 129382 [details] [diff] [review]
proposed fix without reply on top sig quoting
r/a=sspitzer for 1.5 beta
Attachment #129382 -
Flags: review+
Attachment #129382 -
Flags: approval1.5b+
Comment 18•22 years ago
|
||
Comment on attachment 129382 [details] [diff] [review]
proposed fix without reply on top sig quoting
r/a=sspitzer for 1.5 beta
Comment 19•22 years ago
|
||
fix checked in.
Status: REOPENED → RESOLVED
Closed: 23 years ago → 22 years ago
Resolution: --- → FIXED
Reporter | ||
Comment 20•22 years ago
|
||
Verified/Fixed with 2003081104 Windows 2000
Can't believe this bug that stayed for so long was that easy to fix.
I should have upped the priority early.
Watching the patch, I can't help, but think that this kind of errors occurs
mostly because the string/MIME API is too complex, and a better conceived API
would reduce the probility of such errors.
I hope to be able to put my money where my mouth is someday, and suggest
changes, but that would mean a major rewrite.
Status: RESOLVED → VERIFIED
Updated•22 years ago
|
Flags: blocking1.5b?
Comment 21•22 years ago
|
||
FWIW: Also verifying:
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5b) Gecko/20030818
pi
Updated•21 years ago
|
Attachment #129382 -
Flags: approval1.4.x?
Comment 22•21 years ago
|
||
Comment on attachment 129382 [details] [diff] [review]
proposed fix without reply on top sig quoting
This is not going to make 1.4.1. Please re-request aproval after 1.4.1 ships
if you'd like to get this in for 1.4.2.
Attachment #129382 -
Flags: approval1.4.x? → approval1.4.x-
Updated•21 years ago
|
Flags: blocking1.4.1? → blocking1.4.1-
Updated•20 years ago
|
Product: MailNews → Core
Updated•17 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•