diff options
author | Sergei Golubchik <sergii@pisem.net> | 2013-03-27 10:03:28 +0100 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2013-03-27 10:03:28 +0100 |
commit | 6599fd3e9c23a8957a63146cbe6a0ffc4c292a3d (patch) | |
tree | 5a7e05e0a9abb5f5cc2672bc3d545ac3f5f7fa43 /storage | |
parent | 102a7a2a763dc5f2da8dd1f9ca9a53664c5aad6a (diff) | |
parent | e308d7417bc4ceb1b3b72cac2642015b88f310ff (diff) | |
download | mariadb-git-6599fd3e9c23a8957a63146cbe6a0ffc4c292a3d.tar.gz |
5.3 merge
Diffstat (limited to 'storage')
-rw-r--r-- | storage/myisammrg/ha_myisammrg.cc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/storage/myisammrg/ha_myisammrg.cc b/storage/myisammrg/ha_myisammrg.cc index 47a3abb78d2..bf27e7c2284 100644 --- a/storage/myisammrg/ha_myisammrg.cc +++ b/storage/myisammrg/ha_myisammrg.cc @@ -331,6 +331,19 @@ extern "C" int myisammrg_parent_open_callback(void *callback_param, CPP_UNNAMED_NS_END +/* + Set external_ref for the child MyISAM tables. They need this to be set in + order to check for killed status. +*/ +static void myrg_set_external_ref(MYRG_INFO *m_info, void *ext_ref_arg) +{ + int i; + for (i= 0; i < (int)m_info->tables; i++) + { + m_info->open_tables[i].table->external_ref= ext_ref_arg; + } +} + /** Open a MERGE parent table, but not its children. @@ -394,6 +407,7 @@ int ha_myisammrg::open(const char *name, int mode __attribute__((unused)), } file->children_attached= TRUE; + myrg_set_external_ref(file, (void*)table); info(HA_STATUS_NO_LOCK | HA_STATUS_VARIABLE | HA_STATUS_CONST); } |