diff options
-rw-r--r-- | sql/share/charsets/cp852.xml | 2 | ||||
-rw-r--r-- | strings/ctype-simple.c | 9 |
2 files changed, 11 insertions, 0 deletions
diff --git a/sql/share/charsets/cp852.xml b/sql/share/charsets/cp852.xml index ee434859233..958587d0399 100644 --- a/sql/share/charsets/cp852.xml +++ b/sql/share/charsets/cp852.xml @@ -114,6 +114,8 @@ </map> </collation> +<collation name="cp852_bin" flag="binary"/> + </charset> </charsets> diff --git a/strings/ctype-simple.c b/strings/ctype-simple.c index 8e295b9e13e..fbe702d27ad 100644 --- a/strings/ctype-simple.c +++ b/strings/ctype-simple.c @@ -1171,6 +1171,15 @@ static my_bool create_fromuni(CHARSET_INFO *cs, void *(*alloc)(uint)) uni_idx idx[PLANE_NUM]; int i,n; + /* + Check that Unicode map is loaded. + It can be not loaded when the collation is + listed in Index.xml but not specified + in the character set specific XML file. + */ + if (!cs->tab_to_uni) + return TRUE; + /* Clear plane statistics */ bzero(idx,sizeof(idx)); |