diff options
author | unknown <bar@bar.mysql.r18.ru> | 2002-10-10 17:32:24 +0500 |
---|---|---|
committer | unknown <bar@bar.mysql.r18.ru> | 2002-10-10 17:32:24 +0500 |
commit | 16f5d9530833ecc6f0e83dc2eaf1ff287ff6fa46 (patch) | |
tree | 2c0499ee9035354fc416d50589d4d590dc17841b | |
parent | 08f44a43658eea5034a35b706ae65c678be0160b (diff) | |
download | mariadb-git-16f5d9530833ecc6f0e83dc2eaf1ff287ff6fa46.tar.gz |
Don't use sort_order directly
-rw-r--r-- | myisam/ft_static.c | 2 | ||||
-rw-r--r-- | mysys/my_handler.c | 23 |
2 files changed, 3 insertions, 22 deletions
diff --git a/myisam/ft_static.c b/myisam/ft_static.c index 0b22d296206..5c2629e9e9e 100644 --- a/myisam/ft_static.c +++ b/myisam/ft_static.c @@ -36,7 +36,7 @@ const HA_KEYSEG ft_keysegs[FT_SEGS]={ HA_FT_WLEN, /* start */ #endif /* EVAL_RUN */ 0, /* null_pos */ - NULL /* sort_order */ + NULL /* charset */ }, #ifdef EVAL_RUN { diff --git a/mysys/my_handler.c b/mysys/my_handler.c index af1bf7037f9..2d51ab13f69 100644 --- a/mysys/my_handler.c +++ b/mysys/my_handler.c @@ -20,28 +20,9 @@ int mi_compare_text(CHARSET_INFO *charset_info, uchar *a, uint a_length, uchar *b, uint b_length, my_bool part_key) { - int flag; - -#ifdef USE_STRCOLL - if (use_strnxfrm(charset_info)) - { - if (part_key && b_length < a_length) - a_length=b_length; - return my_strnncoll(charset_info, a, a_length, b, b_length); - } - else -#endif - { - uint length= min(a_length,b_length); - uchar *end= a+ length; - uchar *sort_order=charset_info->sort_order; - while (a < end) - if ((flag= (int) sort_order[*a++] - (int) sort_order[*b++])) - return flag; - } if (part_key && b_length < a_length) - return 0; - return (int) (a_length-b_length); + a_length=b_length; + return my_strnncoll(charset_info, a, a_length, b, b_length); } static int compare_bin(uchar *a, uint a_length, uchar *b, uint b_length, |