mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-5067: Valgrind warnings (Invalid read) in QPF_table_access::print_explain
- Query plan footprint (in new terms, "EXPLAIN structure") should always keep a copy of key_name. This is because the table might be a temporary table which may be already freed by the time we use query plan footprint.
This commit is contained in:
@ -106,4 +106,12 @@ explain replace into t1 select * from t0;
|
||||
|
||||
drop table t0, t1;
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-5067: Valgrind warnings (Invalid read) in QPF_table_access::print_explain
|
||||
--echo #
|
||||
CREATE TABLE t1 (i INT) ENGINE=MyISAM;
|
||||
INSERT INTO t1 VALUES (7),(0),(9);
|
||||
|
||||
SELECT * FROM t1 INNER JOIN ( SELECT DISTINCT * FROM t1 ) AS sq ON (sq.i = t1.i);
|
||||
|
||||
DROP TABLE t1;
|
||||
|
Reference in New Issue
Block a user