summaryrefslogtreecommitdiff
path: root/storage/csv/ha_tina.cc
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-04-15 15:09:22 +0200
committerSergei Golubchik <sergii@pisem.net>2013-04-15 15:09:22 +0200
commita9035be5b7a7b3865ddb4ef34a5d0cfc65dfc254 (patch)
treea9df7341e91623f62fe37cd47fce139d8888fc95 /storage/csv/ha_tina.cc
parent3a1c91d87d69ef243b3e78be6089102cafef0a8e (diff)
parentf57ecb7786177e0af3b1e3ec94302720b2e0f967 (diff)
downloadmariadb-git-a9035be5b7a7b3865ddb4ef34a5d0cfc65dfc254.tar.gz
10.0-base merge
Diffstat (limited to 'storage/csv/ha_tina.cc')
-rw-r--r--storage/csv/ha_tina.cc49
1 files changed, 14 insertions, 35 deletions
diff --git a/storage/csv/ha_tina.cc b/storage/csv/ha_tina.cc
index 916c7b151de..c97cfc57bdb 100644
--- a/storage/csv/ha_tina.cc
+++ b/storage/csv/ha_tina.cc
@@ -136,6 +136,16 @@ static void init_tina_psi_keys(void)
}
#endif /* HAVE_PSI_INTERFACE */
+/*
+ If frm_error() is called in table.cc this is called to find out what file
+ extensions exist for this handler.
+*/
+static const char *ha_tina_exts[] = {
+ CSV_EXT,
+ CSM_EXT,
+ NullS
+};
+
static int tina_init_func(void *p)
{
handlerton *tina_hton;
@@ -153,6 +163,7 @@ static int tina_init_func(void *p)
tina_hton->create= tina_create_handler;
tina_hton->flags= (HTON_CAN_RECREATE | HTON_SUPPORT_LOG_TABLES |
HTON_NO_PARTITION);
+ tina_hton->tablefile_extensions= ha_tina_exts;
return 0;
}
@@ -825,21 +836,6 @@ err:
}
/*
- If frm_error() is called in table.cc this is called to find out what file
- extensions exist for this handler.
-*/
-static const char *ha_tina_exts[] = {
- CSV_EXT,
- CSM_EXT,
- NullS
-};
-
-const char **ha_tina::bas_ext() const
-{
- return ha_tina_exts;
-}
-
-/*
Three functions below are needed to enable concurrent insert functionality
for CSV engine. For more details see mysys/thr_lock.c
*/
@@ -1413,9 +1409,9 @@ int ha_tina::rnd_end()
DBUG_RETURN(-1);
/* Open the file again */
- if (((data_file= mysql_file_open(csv_key_file_data,
- share->data_file_name,
- O_RDONLY, MYF(MY_WME))) == -1))
+ if ((data_file= mysql_file_open(csv_key_file_data,
+ share->data_file_name,
+ O_RDONLY, MYF(MY_WME))) == -1)
DBUG_RETURN(my_errno ? my_errno : -1);
/*
As we reopened the data file, increase share->data_file_version
@@ -1754,23 +1750,6 @@ bool ha_tina::check_if_incompatible_data(HA_CREATE_INFO *info,
struct st_mysql_storage_engine csv_storage_engine=
{ MYSQL_HANDLERTON_INTERFACE_VERSION };
-mysql_declare_plugin(csv)
-{
- MYSQL_STORAGE_ENGINE_PLUGIN,
- &csv_storage_engine,
- "CSV",
- "Brian Aker, MySQL AB",
- "CSV storage engine",
- PLUGIN_LICENSE_GPL,
- tina_init_func, /* Plugin Init */
- tina_done_func, /* Plugin Deinit */
- 0x0100 /* 1.0 */,
- NULL, /* status variables */
- NULL, /* system variables */
- NULL, /* config options */
- 0, /* flags */
-}
-mysql_declare_plugin_end;
maria_declare_plugin(csv)
{
MYSQL_STORAGE_ENGINE_PLUGIN,