While I looked into a .map file in src/backend/utils/mb/Unicode, I
notice of a typo in it.
> static const pg_mb_radix_tree euc_jp_from_unicode_tree =
> {
> ..
> 0x, /* offset of table for 1-byte inputs */
> ...
> 0x0040, /* offset of table for 2-byte inputs */
> ...
> 0x02c3, /* offset of table for 3-byte inputs */
> ...
!> 0x, /* offset of table for 3-byte inputs */
> 0x00, /* b4_1_lower */
> 0x00, /* b4_1_upper */
> ...
> };
Yeah, the line above prefixed by '!' is apparently a typo of "4-byte
inputs", which comes from a typo in convutils.pm.
Fortunately make maintainer-clean; make all in the directory results
in no other differences so we can apply the attached patch to fix the
all propagated typos.
I don't think no backpatch is needed.
regards.
--
Kyotaro Horiguchi
NTT Open Source Software Center
diff --git a/src/backend/utils/mb/Unicode/big5_to_utf8.map b/src/backend/utils/mb/Unicode/big5_to_utf8.map
index aa417bc9c8..b8332fb958 100644
--- a/src/backend/utils/mb/Unicode/big5_to_utf8.map
+++ b/src/backend/utils/mb/Unicode/big5_to_utf8.map
@@ -26,7 +26,7 @@ static const pg_mb_radix_tree big5_to_unicode_tree =
0x00, /* b3_3_lower */
0x00, /* b3_3_upper */
- 0x, /* offset of table for 3-byte inputs */
+ 0x, /* offset of table for 4-byte inputs */
0x00, /* b4_1_lower */
0x00, /* b4_1_upper */
0x00, /* b4_2_lower */
diff --git a/src/backend/utils/mb/Unicode/convutils.pm b/src/backend/utils/mb/Unicode/convutils.pm
index 5ad38514be..1155d8bb14 100644
--- a/src/backend/utils/mb/Unicode/convutils.pm
+++ b/src/backend/utils/mb/Unicode/convutils.pm
@@ -579,7 +579,7 @@ sub print_radix_table
printf $out " 0x%02x, /* b3_3_lower */\n", $b3_3_lower;
printf $out " 0x%02x, /* b3_3_upper */\n", $b3_3_upper;
printf $out "\n";
- printf $out " 0x%04x, /* offset of table for 3-byte inputs */\n",
+ printf $out " 0x%04x, /* offset of table for 4-byte inputs */\n",
$b4root;
printf $out " 0x%02x, /* b4_1_lower */\n", $b4_1_lower;
printf $out " 0x%02x, /* b4_1_upper */\n", $b4_1_upper;
diff --git a/src/backend/utils/mb/Unicode/euc_cn_to_utf8.map b/src/backend/utils/mb/Unicode/euc_cn_to_utf8.map
index 3801e08ef5..f8503d30c3 100644
--- a/src/backend/utils/mb/Unicode/euc_cn_to_utf8.map
+++ b/src/backend/utils/mb/Unicode/euc_cn_to_utf8.map
@@ -26,7 +26,7 @@ static const pg_mb_radix_tree euc_cn_to_unicode_tree =
0x00, /* b3_3_lower */
0x00, /* b3_3_upper */
- 0x, /* offset of table for 3-byte inputs */
+ 0x, /* offset of table for 4-byte inputs */
0x00, /* b4_1_lower */
0x00, /* b4_1_upper */
0x00, /* b4_2_lower */
diff --git a/src/backend/utils/mb/Unicode/euc_jis_2004_to_utf8.map b/src/backend/utils/mb/Unicode/euc_jis_2004_to_utf8.map
index d2da4a383b..4b6d4e0d42 100644
--- a/src/backend/utils/mb/Unicode/euc_jis_2004_to_utf8.map
+++ b/src/backend/utils/mb/Unicode/euc_jis_2004_to_utf8.map
@@ -26,7 +26,7 @@ static const pg_mb_radix_tree euc_jis_2004_to_unicode_tree =
0xa1, /* b3_3_lower */
0xfe, /* b3_3_upper */
- 0x, /* offset of table for 3-byte inputs */
+ 0x, /* offset of table for 4-byte inputs */
0x00, /* b4_1_lower */
0x00, /* b4_1_upper */
0x00, /* b4_2_lower */
diff --git a/src/backend/utils/mb/Unicode/euc_jp_to_utf8.map b/src/backend/utils/mb/Unicode/euc_jp_to_utf8.map
index 96b79a58a1..ee23de2c8f 100644
--- a/src/backend/utils/mb/Unicode/euc_jp_to_utf8.map
+++ b/src/backend/utils/mb/Unicode/euc_jp_to_utf8.map
@@ -26,7 +26,7 @@ static const pg_mb_radix_tree euc_jp_to_unicode_tree =
0xa1, /* b3_3_lower */
0xfe, /* b3_3_upper */
- 0x, /* offset of table for 3-byte inputs */
+ 0x, /* offset of table for 4-byte inputs */
0x00, /* b4_1_lower */
0x00, /* b4_1_upper */
0x00, /* b4_2_lower */
diff --git a/src/backend/utils/mb/Unicode/euc_kr_to_utf8.map b/src/backend/utils/mb/Unicode/euc_kr_to_utf8.map
index bf1fc4a98b..5d6bcc53ae 100644
--- a/src/backend/utils/mb/Unicode/euc_kr_to_utf8.map
+++ b/src/backend/utils/mb/Unicode/euc_kr_to_utf8.map
@@ -26,7 +26,7 @@ static const pg_mb_radix_tree euc_kr_to_unicode_tree =
0x00, /* b3_3_lower */
0x00, /* b3_3_upper */
- 0x, /* offset of table for 3-byte inputs */
+ 0x, /* offset of table for 4-byte inputs */
0x00, /* b4_1_lower */
0x00, /* b4_1_upper */
0x00, /* b4_2_lower */
diff --git a/src/backend/utils/mb/Unicode/euc_tw_to_utf8.map b/src/backend/utils/mb/Unicode/euc_tw_to_utf8.map
index 22af269924..5a1774617f 100644
--- a/src/backend/utils/mb/Unicode/euc_tw_to_utf8.map
+++ b/src/backend/utils/mb/Unicode/euc_tw_to_utf8.map
@@ -26,7 +26,7 @@ static const pg_mb_radix_tree euc_tw_to_unicode_tree =
0x00, /* b3_3_lower */
0x00, /* b3_3_upper */
- 0x1899, /* offset of table for 3-byte inputs */
+ 0x1899, /* offset of table for 4-byte inputs */
0x8e, /* b4_1_lower */
0x8e, /* b4_1_upper */
0xa1, /* b4_2_lower */
diff --git a/src/backend/utils/mb/Unicode/gb18030_to_utf8.map b/src/backend/