From kde-commits Tue Oct 02 04:21:20 2007 From: Maks Orlovich Date: Tue, 02 Oct 2007 04:21:20 +0000 To: kde-commits Subject: branches/KDE/3.5/kdelibs/kjs Message-Id: <1191298880.366515.16311.nullmailer () svn ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=119129888925302 SVN commit 719916 by orlovich: Fix a bad regression caused by a bug in the stricter utf-8 validation code that caused us to replace latin1 glyphs (e.g. accented chars) with the unicode replacement character. BUG:150381 M +2 -2 function.cpp --- branches/KDE/3.5/kdelibs/kjs/function.cpp #719915:719916 @@ -250,8 +250,8 @@ unsigned long yyyyy = octets[0] & 0x1F; unsigned long zzzzzz = octets[1] & 0x3F; V = (yyyyy << 6) | zzzzzz; - // 2-byte sequence overlong for this value? - if (V < 0xFF) + // 2-byte sequence overlong for this value? + if (V < 0x80) V = replacementChar; C = UChar((unsigned short)V); }