diff options
author | unknown <bar@bar.mysql.r18.ru> | 2003-05-21 13:58:30 +0500 |
---|---|---|
committer | unknown <bar@bar.mysql.r18.ru> | 2003-05-21 13:58:30 +0500 |
commit | 4dbef8c2e3a432dc2efc9f91270e1e1ea53a8399 (patch) | |
tree | 72688c30afa116976f83d75dfdf3c0ac9c5185a8 /mysys/charset.c | |
parent | 32cd85e9157ae95553fe019a3d8ebd78040c4001 (diff) | |
download | mariadb-git-4dbef8c2e3a432dc2efc9f91270e1e1ea53a8399.tar.gz |
"character_sets" has been removed from SHOW VARIABLES. Use SHOW CHARACTER SET instead.
"character_set_system" has been added to display the system character set
Diffstat (limited to 'mysys/charset.c')
-rw-r--r-- | mysys/charset.c | 67 |
1 files changed, 0 insertions, 67 deletions
diff --git a/mysys/charset.c b/mysys/charset.c index 097c35caa56..2d9500e4b0d 100644 --- a/mysys/charset.c +++ b/mysys/charset.c @@ -688,70 +688,3 @@ static void charset_append(DYNAMIC_STRING *s, const char *name) dynstr_append(s, " "); } } - - -/* Returns a dynamically-allocated string listing the character sets - requested. The caller is responsible for freeing the memory. */ - -char *list_charsets(myf want_flags) -{ - DYNAMIC_STRING s; - char *p; - - (void)init_available_charsets(MYF(0)); - init_dynamic_string(&s, NullS, 256, 1024); - - if (want_flags & MY_CS_COMPILED) - { - CHARSET_INFO **cs; - for (cs= all_charsets; cs < all_charsets+255; cs++) - { - if (cs[0]) - { - dynstr_append(&s, cs[0]->name); - dynstr_append(&s, " "); - } - } - } - - if (want_flags & MY_CS_CONFIG) - { - CHARSET_INFO **cs; - char buf[FN_REFLEN]; - MY_STAT status; - - for (cs=all_charsets; cs < all_charsets+255; cs++) - { - if (!cs[0] || !cs[0]->name || charset_in_string(cs[0]->name, &s)) - continue; - get_charset_conf_name(cs[0]->name, buf); - if (!my_stat(buf, &status, MYF(0))) - continue; /* conf file doesn't exist */ - dynstr_append(&s, cs[0]->name); - dynstr_append(&s, " "); - } - } - - if (want_flags & (MY_CS_INDEX|MY_CS_LOADED)) - { - CHARSET_INFO **cs; - for (cs= all_charsets; cs < all_charsets + 255; cs++) - if (cs[0] && cs[0]->name && (cs[0]->state & want_flags) ) - charset_append(&s, cs[0]->name); - } - - if (s.length) - { - s.str[s.length - 1]= '\0'; /* chop trailing space */ - p= my_strdup(s.str, MYF(MY_WME)); - } - else - { - p= my_strdup("", MYF(MY_WME)); - } - dynstr_free(&s); - - return p; -} - - |