Commit 28b5074e authored by unknown's avatar unknown
Browse files

sql_show.cc:

  Don't display charsets/collations with HIDDEN flag.
ctype-utf8.c:
  Adding HIDDEN flag to "filename"
  Changeing ID to 17 which was previosly
  used by deprecated "win1251", removed in 4.1.
charset-def.c:
  Adding "filename" as a hidden charset, for test purposes.
m_ctype.h:
  Adding MY_CS_HIDDEN flag,
  to hide charsets and collations from
  being displayed in SHOW.


include/m_ctype.h:
  Adding MY_CS_HIDDEN flag,
  to hide charsets and collations from
  being displayed in SHOW.
mysys/charset-def.c:
  Adding "filename" as a hidden charset, for test purposes.
strings/ctype-utf8.c:
  Adding HIDDEN flag to "filename"
  Changeing ID to 17 which was previosly
  used by deprecated "win1251", removed in 4.1.
sql/sql_show.cc:
  Don't display charsets/collations with HIDDEN flag.
parent aae47851
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -67,6 +67,7 @@ extern MY_UNICASE_INFO *my_unicase_turkish[256];
#define MY_CS_READY	256    /* if a charset is initialized    */
#define MY_CS_AVAILABLE	512    /* If either compiled-in or loaded*/
#define MY_CS_CSSORT	1024   /* if case sensitive sort order   */
#define MY_CS_HIDDEN	2048   /* don't display in SHOW          */	
#define MY_CHARSET_UNDEFINED 0


+1 −0
Original line number Diff line number Diff line
@@ -78,6 +78,7 @@ my_bool init_compiled_charsets(myf flags __attribute__((unused)))
  CHARSET_INFO *cs;

  add_compiled_collation(&my_charset_bin);
  add_compiled_collation(&my_charset_filename);
  
  add_compiled_collation(&my_charset_latin1);
  add_compiled_collation(&my_charset_latin1_bin);
+2 −0
Original line number Diff line number Diff line
@@ -2835,6 +2835,7 @@ int fill_schema_charsets(THD *thd, TABLE_LIST *tables, COND *cond)
    CHARSET_INFO *tmp_cs= cs[0];
    if (tmp_cs && (tmp_cs->state & MY_CS_PRIMARY) && 
        (tmp_cs->state & MY_CS_AVAILABLE) &&
        !(tmp_cs->state & MY_CS_HIDDEN) &&
        !(wild && wild[0] &&
	  wild_case_compare(scs, tmp_cs->csname,wild)))
    {
@@ -2904,6 +2905,7 @@ int fill_schema_collation(THD *thd, TABLE_LIST *tables, COND *cond)
    CHARSET_INFO **cl;
    CHARSET_INFO *tmp_cs= cs[0];
    if (!tmp_cs || !(tmp_cs->state & MY_CS_AVAILABLE) || 
         (tmp_cs->state & MY_CS_HIDDEN) ||
        !(tmp_cs->state & MY_CS_PRIMARY))
      continue;
    for (cl= all_charsets; cl < all_charsets+255 ;cl ++)
+2 −2
Original line number Diff line number Diff line
@@ -4048,8 +4048,8 @@ static MY_CHARSET_HANDLER my_charset_filename_handler=

CHARSET_INFO my_charset_filename=
{
    33,0,0,             /* number       */
    MY_CS_COMPILED|MY_CS_PRIMARY|MY_CS_STRNXFRM|MY_CS_UNICODE,  /* state  */
    17,0,0,             /* number       */
    MY_CS_COMPILED|MY_CS_PRIMARY|MY_CS_STRNXFRM|MY_CS_UNICODE|MY_CS_HIDDEN,
    "filename",         /* cs name      */
    "filename",         /* name         */
    "",                 /* comment      */