87
# Test for bug#21216 "Simultaneous DROP TABLE and SHOW OPEN TABLES causes
88
# server to crash". Crash (caused by failed assertion in 5.0 or by null
89
# pointer dereference in 5.1) happened when one ran SHOW OPEN TABLES
90
# while concurrently doing DROP TABLE (or RENAME TABLE, CREATE TABLE LIKE
91
# or any other command that takes name-lock) in other connection.
93
# Also includes test for similar bug#12212 "Crash that happens during
94
# removing of database name from cache" reappeared in 5.1 as bug#19403
95
# In its case crash happened when one concurrently executed DROP DATABASE
96
# and one of name-locking command.
99
drop database if exists mysqltest;
100
drop table if exists t1;
102
create table t1 (i int);
103
create database mysqltest;
104
connect (addconroot1, localhost, root,,);
106
connect (addconroot2, localhost, root,,);
107
# Server should not crash in any of the following statements
111
--send drop database mysqltest
114
connection addconroot1;
116
connection addconroot2;
118
disconnect addconroot1;
119
disconnect addconroot2;
122
85
--echo End of 5.0 tests