Closed Bug 191483 Opened 22 years ago Closed 22 years ago

bugs in intl/uconv/src/nsUnicodeToUTF8.cpp

Categories

(Core :: Internationalization, defect)

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: ftang, Assigned: smontagu)

References

Details

Attachments

(1 file)

I saw several bugs in this file 110 if ( *src < 0x007f) { Isn't it true this should be either 110 if ( *src <= 0x007f) { or 110 if ( *src < 0x0080) { Isn't the following line 115 } else if (*src < 0x07ff) { should be 115 } else if (*src <= 0x07ff) { or 115 } else if (*src < 0x0800) { I think the following is defintely wrong 121 } else if (*src >= (PRUnichar)0xD800 && *src < (PRUnichar)0xDA00) { it should be 121 } else if (*src >= (PRUnichar)0xD800 && *src < (PRUnichar)0xDC00) { right? where the DA00 come from ?
Blocks: 182751
Comment on attachment 124483 [details] [diff] [review] Patch with ftang's fixes r=smontagu. Thanks for picking this up!
Attachment #124483 - Flags: review+
Attachment #124483 - Flags: superreview?(rbs)
Comment on attachment 124483 [details] [diff] [review] Patch with ftang's fixes sr=rbs (I would have preferred the <= variant, as it is more readable and saves the reader from guessing.)
Attachment #124483 - Flags: superreview?(rbs) → superreview+
Fix checked in (in <= form)
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
This is a simple fix that looks good and I think that this is important to have an absolutly correct conversion from Unicode to UTF8 for Mozilla 1.4 Reporter and assignee should comment on the value and risk of this fix. I don't know whether I should request approval1.4 for the patch or set blocking 1.4? but I'm asking that this patch is checked in on the 1.4 branch
Flags: blocking1.4?
mozilla1.4 shipped. unsetting blocking1.4 request.
Flags: blocking1.4?
Blocks: 86411
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: