Commit b9b41a5f authored by Sergei Golubchik's avatar Sergei Golubchik

fix plugin.test - bad merge in TABLE_SHARE::destroy, ha_share must be deleted before the plugin

parent d641028f
......@@ -15,7 +15,7 @@ PLUGIN_STATUS ACTIVE
PLUGIN_TYPE STORAGE ENGINE
PLUGIN_TYPE_VERSION #
PLUGIN_LIBRARY ha_example.so
PLUGIN_LIBRARY_VERSION 1.4
PLUGIN_LIBRARY_VERSION 1.5
PLUGIN_AUTHOR Brian Aker, MySQL AB
PLUGIN_DESCRIPTION Example storage engine
PLUGIN_LICENSE GPL
......@@ -28,7 +28,7 @@ PLUGIN_STATUS ACTIVE
PLUGIN_TYPE DAEMON
PLUGIN_TYPE_VERSION #
PLUGIN_LIBRARY ha_example.so
PLUGIN_LIBRARY_VERSION 1.4
PLUGIN_LIBRARY_VERSION 1.5
PLUGIN_AUTHOR Sergei Golubchik
PLUGIN_DESCRIPTION Unusable Daemon
PLUGIN_LICENSE GPL
......@@ -57,7 +57,7 @@ PLUGIN_STATUS DELETED
PLUGIN_TYPE STORAGE ENGINE
PLUGIN_TYPE_VERSION #
PLUGIN_LIBRARY ha_example.so
PLUGIN_LIBRARY_VERSION 1.4
PLUGIN_LIBRARY_VERSION 1.5
PLUGIN_AUTHOR Brian Aker, MySQL AB
PLUGIN_DESCRIPTION Example storage engine
PLUGIN_LICENSE GPL
......
......@@ -429,6 +429,12 @@ void TABLE_SHARE::destroy()
DBUG_ENTER("TABLE_SHARE::destroy");
DBUG_PRINT("info", ("db: %s table: %s", db.str, table_name.str));
if (ha_share)
{
delete ha_share;
ha_share= NULL; // Safety
}
free_root(&stats_cb.mem_root, MYF(0));
stats_cb.stats_can_be_read= FALSE;
stats_cb.stats_is_read= FALSE;
......@@ -451,12 +457,6 @@ void TABLE_SHARE::destroy()
info_it->flags= 0;
}
}
if (ha_share)
{
delete ha_share;
ha_share= NULL; // Safety
}
#ifdef HAVE_PSI_TABLE_INTERFACE
PSI_TABLE_CALL(release_table_share)(m_psi);
#endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment