summaryrefslogtreecommitdiff
path: root/strings
diff options
context:
space:
mode:
authorunknown <bar@mysql.com/bar.myoffice.izhnet.ru>2007-05-30 12:30:15 +0500
committerunknown <bar@mysql.com/bar.myoffice.izhnet.ru>2007-05-30 12:30:15 +0500
commitc7dfc326d420409b794a81837ec1da5c13df24eb (patch)
treec34b49fac69ebd8b0b1fc27411dac28a851b0bfc /strings
parent8ca545eca2fa5d575d3449380a938b2c55ebed65 (diff)
downloadmariadb-git-c7dfc326d420409b794a81837ec1da5c13df24eb.tar.gz
Bug#28600 Yen sign and overline ujis conversion change
Problem: Unicode->UJIS followed incorrect conversion rules for U+00A5 YEN SIGN and U+203E OVERLINE, so these characters were converted to ujis 0x8E5C and 0x8E7E accordingly. This behaviour would be correct for a JIS-X-0201 based character set, but this is wrong for UJIS, which is documented as x-eucjp-unicode-0.9, and which is based on ASCII for the range U+0000..U+007F. Fix: removing JIS-X-0201 conversion rules, making UJIS ASCII compatible. YEN SIGN and OVERLINE do not have corresponding UJIS characters anymore and converted to 0x3F QUESTION MARK, throwing a warning in appropriative cases. This patch also includes a test covering full UJIS->Unicode->UJIS mapping. sql/field.cc: Nicer error message format: always use HEX notation when printing warnings about UCS2 values - this is more readable. strings/ctype-ujis.c: Removing incorrect Unicode->UJIS mapping. MySQL "UJIS" is x-eucjp-unicode-0.9. mysql-test/r/ctype_ujis_ucs2.result: New BitKeeper file ``mysql-test/r/ctype_ujis_ucs2.result'' mysql-test/t/ctype_ujis_ucs2.test: New BitKeeper file ``mysql-test/t/ctype_ujis_ucs2.test''
Diffstat (limited to 'strings')
-rw-r--r--strings/ctype-ujis.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/strings/ctype-ujis.c b/strings/ctype-ujis.c
index d1e11071886..55454cbe7ed 100644
--- a/strings/ctype-ujis.c
+++ b/strings/ctype-ujis.c
@@ -264,18 +264,6 @@ my_wc_mb_jisx0201(CHARSET_INFO *cs __attribute__((unused)),
return 1;
}
- if (wc == 0x00A5)
- {
- *s = 0x5C;
- return 1;
- }
-
- if (wc == 0x203E)
- {
- *s = 0x7E;
- return 1;
- }
-
return MY_CS_ILUNI;
}