summaryrefslogtreecommitdiff
path: root/sql/sql_class.h
diff options
context:
space:
mode:
authorSergey Vojtovich <svoj@mariadb.org>2018-09-12 16:36:45 +0400
committerMarko Mäkelä <marko.makela@mariadb.com>2019-05-14 15:23:09 +0300
commit95fb88d5469e9d601aa9c2f319d1b561925e9795 (patch)
tree396d6a2a905c35027324fce33d595441a71e3d4c /sql/sql_class.h
parent43bbf88dcbab470947af0567f265d9659b07aab8 (diff)
downloadmariadb-git-95fb88d5469e9d601aa9c2f319d1b561925e9795.tar.gz
MDEV-17167 - InnoDB: Failing assertion: table->get_ref_count() == 0 upon
truncating a temporary table TRUNCATE expects only one TABLE instance (which is used by TRUNCATE itself) to be open. However this requirement wasn't enforced after "MDEV-5535: Cannot reopen temporary table". Fixed by closing unused table instances before performing TRUNCATE.
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r--sql/sql_class.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h
index f640113d946..fac489a44ee 100644
--- a/sql/sql_class.h
+++ b/sql/sql_class.h
@@ -4350,6 +4350,7 @@ public:
TMP_TABLE_SHARE* save_tmp_table_share(TABLE *table);
void restore_tmp_table_share(TMP_TABLE_SHARE *share);
+ void close_unused_temporary_table_instances(const TABLE_LIST *tl);
private:
/* Whether a lock has been acquired? */