Closed Bug 73243 Opened 25 years ago Closed 25 years ago

Folder default charset is broken for mail header

Categories

(MailNews Core :: Internationalization, defect)

All
Windows 95
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: ji, Assigned: jgmyers)

Details

(Keywords: intl)

Attachments

(1 file)

***Observed with linux, win32, and Mac 03/21 mtrunk build*** The mails w/o MIME header don't use the folder charset now. It used to be working even at 03/20 build. Steps to reproduce: 1. Select a mail w/o MIME header. 2. Change the folder charset to the proper charset and reselect the folder. The mail w/o MIME header still garbled header on the thread pane and envelope.
This is about folder default charset, changed the summary. Reassign to jgmyers, his checked in for bug 65277 on 3/20 might be related. John, is the default charset supposed to be working now, or you need more changes to be checked in.
Assignee: nhotta → jgmyers
Keywords: intl
Summary: Charset override is broken for mail header → Folder default charset is broken for mail header
Estimate two more checkins for bug 65277.
1051 static PRBool intl_is_legal_utf8(const char *input, unsigned len) 1052 { 1053 int c; 1054 1055 while (len) { 1056 c = (unsigned char)*input++; 1057 len--; 1058 if (c == 0x1B) break; In case of ISO-2022-JP header with no MIME encoded, it has 0x1B and the function returns true, then the caller just dup the string without using the default charset. Why do you check for 0x1B there?
Keywords: nsbeta1
That was a transcription error when I pulled the UTF-8 detection code into a separate routine. Fix: Index: comi18n.cpp =================================================================== RCS file: /cvsroot/mozilla/mailnews/mime/src/comi18n.cpp,v retrieving revision 1.80 diff -u -r1.80 comi18n.cpp --- comi18n.cpp 2001/03/20 00:47:41 1.80 +++ comi18n.cpp 2001/03/29 02:53:47 @@ -1055,7 +1055,7 @@ while (len) { c = (unsigned char)*input++; len--; - if (c == 0x1B) break; + if (c == 0x1B) return PR_FALSE; if ((c & 0x80) == 0) continue; if ((c & 0xE0) == 0xC0) { if (len < 1 || (*input & 0xC0) != 0x80 ||
r=nhotta
Fix checked in.
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Verified with 04/02 build. It's fixed.
Status: RESOLVED → VERIFIED
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: