limit ToUCS2 only have effect in U+0080 to U+009F range so it won't mess up non Latin 1 characters
git-svn-id: svn://10.0.0.236/trunk@19020 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -468,7 +468,8 @@ void nsString::ToUCS2(PRInt32 aStartOffset){
|
||||
chartype* end = cp + mLength;
|
||||
while (cp < end) {
|
||||
unsigned char ch = (unsigned char)*cp;
|
||||
*cp=gToUCS2[ch];
|
||||
if( 0x0080 == (0xFFE0 & (*cp)) ) // limit to only 0x0080 to 0x009F
|
||||
*cp=gToUCS2[ch];
|
||||
cp++;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user