Closed Bug 223707 Opened 22 years ago Closed 22 years ago

IS_CJK_CHAR should not return true for u > 0xFFEF

Categories

(Core :: Internationalization, defect)

x86
Linux
defect
Not set
trivial

Tracking

()

RESOLVED FIXED

People

(Reporter: timeless, Assigned: timeless)

References

()

Details

Attachments

(1 file, 1 obsolete file)

2. intl/lwbrk/src/nsJISx4501LineBreaker.cpp:238 (See build log excerpt) Comparison is always true due to limited range of data type 233 IS_CJK_CHAR(PRUnichar u) 238 (0xff00 <= (u) && (u) <= 0xffff) ); 0xffff is the upperbound for PRUnichar
Attached file wrongly drop incorrect expression (obsolete) —
Attachment #134152 - Flags: superreview?(smontagu)
Attachment #134152 - Flags: review?(smontagu)
Attachment #134152 - Flags: superreview?(smontagu) → superreview?(bzbarsky)
Shouldn't that test really be |(u) <= 0xfffd|? That function is supposedly checking for CJK characters which 0xfffe and 0xffff certainly aren't.
the upperbound had better be U+FFEF. Well, line breaking code needs some overhaul, anyway.
Comment on attachment 134152 [details] wrongly drop incorrect expression sr- based on jshin's comments.
Attachment #134152 - Flags: superreview?(bzbarsky) → superreview-
Status: NEW → ASSIGNED
Summary: Comparison is always true due to limited range of data type → IS_CJK_CHAR should not return true for u > 0xFFEF
Attachment #134152 - Attachment description: drop useless expression → wrongly drop incorrect expression
Attachment #134152 - Flags: review?(smontagu)
Attachment #134152 - Attachment is obsolete: true
Attachment #134152 - Attachment is patch: false
Attachment #134181 - Flags: review?(jshin)
Attachment #134181 - Flags: review?(jshin) → review?(smontagu)
Comment on attachment 134181 [details] [diff] [review] change bound from 0xffff to 0xffef Yes, FFEF is the right thing to test for. r=me
Attachment #134181 - Flags: review?(smontagu) → review+
Attachment #134181 - Flags: superreview?(tor)
Attachment #134181 - Flags: superreview?(tor) → superreview?(roc)
Attachment #134181 - Flags: superreview?(roc) → superreview+
checked in
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: