1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

New ctype functions/macros to support many charsets at a time

This commit is contained in:
bar@gw.udmsearch.izhnet.ru
2002-03-12 21:37:58 +04:00
parent 4237e7ace7
commit b37ce8e769
83 changed files with 1336 additions and 956 deletions

View File

@ -1282,8 +1282,8 @@ STDCALL mysql_rpl_query_type(const char* q, int len)
for(; q < q_end; ++q)
{
char c;
if (isalpha(c=*q))
switch(tolower(c))
if (my_isalpha(system_charset_info,c=*q))
switch(my_tolower(system_charset_info,c))
{
case 'i': /* insert */
case 'u': /* update or unlock tables */
@ -1292,9 +1292,11 @@ STDCALL mysql_rpl_query_type(const char* q, int len)
case 'a': /* alter */
return MYSQL_RPL_MASTER;
case 'c': /* create or check */
return tolower(q[1]) == 'h' ? MYSQL_RPL_ADMIN : MYSQL_RPL_MASTER ;
return my_tolower(system_charset_info,q[1]) == 'h' ? MYSQL_RPL_ADMIN :
MYSQL_RPL_MASTER;
case 's': /* select or show */
return tolower(q[1]) == 'h' ? MYSQL_RPL_ADMIN : MYSQL_RPL_SLAVE;
return my_tolower(system_charset_info,q[1]) == 'h' ? MYSQL_RPL_ADMIN :
MYSQL_RPL_SLAVE;
case 'f': /* flush */
case 'r': /* repair */
case 'g': /* grant */