Fixed ASAN heap-use-after-free handler::ha_index_or_rnd_end
MDEV-16123 ASAN heap-use-after-free handler::ha_index_or_rnd_end MDEV-13828 Segmentation fault on RENAME TABLE Problem was that destructor called methods for closed table. Fixed by removing code in destructor.
This commit is contained in:
parent
908676dfd9
commit
a816aa066e
6
mysql-test/r/statistics_close.result
Normal file
6
mysql-test/r/statistics_close.result
Normal file
@ -0,0 +1,6 @@
|
||||
CREATE TABLE t1 (i int);
|
||||
RENAME TABLE t1 TO t2;
|
||||
FLUSH TABLES;
|
||||
DROP TABLE IF EXISTS t1, t2;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 'test.t1'
|
18
mysql-test/t/statistics_close.test
Normal file
18
mysql-test/t/statistics_close.test
Normal file
@ -0,0 +1,18 @@
|
||||
#
|
||||
# MDEV-16123 ASAN heap-use-after-free handler::ha_index_or_rnd_end
|
||||
# MDEV-13828 Segmentation fault on RENAME TABLE
|
||||
#
|
||||
|
||||
CREATE TABLE t1 (i int);
|
||||
--connect (con1,localhost,root,,test)
|
||||
--send
|
||||
RENAME TABLE t1 TO t2;
|
||||
--connection default
|
||||
FLUSH TABLES;
|
||||
--connection con1
|
||||
--reap
|
||||
|
||||
# Cleanup
|
||||
--disconnect con1
|
||||
--connection default
|
||||
DROP TABLE IF EXISTS t1, t2;
|
@ -1376,7 +1376,8 @@ public:
|
||||
|
||||
~Stat_table_write_iter()
|
||||
{
|
||||
cleanup();
|
||||
/* Ensure that cleanup has been run */
|
||||
DBUG_ASSERT(rowid_buf == 0);
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user