null+****@clear*****
null+****@clear*****
2011年 11月 27日 (日) 09:29:30 JST
Kouhei Sutou 2011-11-27 00:29:30 +0000 (Sun, 27 Nov 2011)
New Revision: 1f0c9978dfd6494d018f6f532ffeafa8889aaf7e
Log:
remove needless wrapper. refs #1168
Modified files:
ha_mroonga.cc
mrn_table.cc
mrn_table.h
Modified: ha_mroonga.cc (+4 -4)
===================================================================
--- ha_mroonga.cc 2011-11-26 08:29:56 +0000 (90c6f13)
+++ ha_mroonga.cc 2011-11-27 00:29:30 +0000 (167a399)
@@ -2834,7 +2834,7 @@ int ha_mroonga::delete_table(const char *name)
#endif
if (!(tmp_share = mrn_get_share(name, &tmp_table, &error)))
{
- mrn_q_free_table_share(tmp_table_share);
+ free_table_share(tmp_table_share);
DBUG_RETURN(error);
}
@@ -2847,7 +2847,7 @@ int ha_mroonga::delete_table(const char *name)
mrn_free_share(tmp_share);
mysql_mutex_lock(&LOCK_open);
- mrn_q_free_table_share(tmp_table_share);
+ free_table_share(tmp_table_share);
mysql_mutex_unlock(&LOCK_open);
DBUG_RETURN(error);
}
@@ -7315,7 +7315,7 @@ int ha_mroonga::rename_table(const char *from, const char *to)
#endif
if (!(tmp_share = mrn_get_share(from, &tmp_table, &error)))
{
- mrn_q_free_table_share(tmp_table_share);
+ free_table_share(tmp_table_share);
DBUG_RETURN(error);
}
@@ -7355,7 +7355,7 @@ int ha_mroonga::rename_table(const char *from, const char *to)
if (to_tbl_name[0] != '#')
{
mysql_mutex_lock(&LOCK_open);
- mrn_q_free_table_share(tmp_table_share);
+ free_table_share(tmp_table_share);
mysql_mutex_unlock(&LOCK_open);
}
DBUG_RETURN(error);
Modified: mrn_table.cc (+1 -19)
===================================================================
--- mrn_table.cc 2011-11-26 08:29:56 +0000 (23b7c4c)
+++ mrn_table.cc 2011-11-27 00:29:30 +0000 (8d61c2d)
@@ -747,17 +747,6 @@ TABLE_SHARE *mrn_get_table_share(TABLE_LIST *table_list, int *error)
DBUG_RETURN(share);
}
-void mrn_free_table_share(TABLE_SHARE *share)
-{
- DBUG_ENTER("mrn_free_table_share");
-#if MYSQL_VERSION_ID >= 50500
- release_table_share(share);
-#else
- release_table_share(share, RELEASE_NORMAL);
-#endif
- DBUG_VOID_RETURN;
-}
-
TABLE_SHARE *mrn_q_get_table_share(TABLE_LIST *table_list, const char *path,
int *error)
{
@@ -793,13 +782,6 @@ TABLE_SHARE *mrn_q_get_table_share(TABLE_LIST *table_list, const char *path,
DBUG_RETURN(share);
}
-void mrn_q_free_table_share(TABLE_SHARE *share)
-{
- DBUG_ENTER("mrn_q_free_table_share");
- share->destroy();
- DBUG_VOID_RETURN;
-}
-
KEY *mrn_create_key_info_for_table(MRN_SHARE *share, TABLE *table, int *error)
{
uint *wrap_key_nr = share->wrap_key_nr, i, j;
@@ -904,7 +886,7 @@ void mrn_clear_alter_share(THD *thd)
while (alter_share)
{
tmp_alter_share = alter_share->next;
- mrn_q_free_table_share(alter_share->alter_share);
+ free_table_share(alter_share->alter_share);
free(alter_share);
alter_share = tmp_alter_share;
}
Modified: mrn_table.h (+0 -2)
===================================================================
--- mrn_table.h 2011-11-26 08:29:56 +0000 (9c08b2d)
+++ mrn_table.h 2011-11-27 00:29:30 +0000 (466092c)
@@ -98,10 +98,8 @@ MRN_SHARE *mrn_get_share(const char *table_name, TABLE *table, int *error);
int mrn_free_share_alloc(MRN_SHARE *share);
int mrn_free_share(MRN_SHARE *share);
TABLE_SHARE *mrn_get_table_share(TABLE_LIST *table_list, int *error);
-void mrn_free_table_share(TABLE_SHARE *share);
TABLE_SHARE *mrn_q_get_table_share(TABLE_LIST *table_list, const char *path,
int *error);
-void mrn_q_free_table_share(TABLE_SHARE *share);
KEY *mrn_create_key_info_for_table(MRN_SHARE *share, TABLE *table, int *error);
void mrn_set_bitmap_by_key(MY_BITMAP *map, KEY *key_info);
uint mrn_decode(uchar *buf_st, uchar *buf_ed,