Commit graph

21 commits

Author SHA1 Message Date
dlenev@mockturtle.local
186fa6c291 Fix for bug#21216 "Simultaneous DROP TABLE and SHOW OPEN TABLES causes
server to crash".

Crash caused by assertion failure happened when one ran SHOW OPEN TABLES
while concurrently doing DROP TABLE (or RENAME TABLE, CREATE TABLE LIKE
or any other command that takes name-lock) in other connection.
For non-debug version of server problem exposed itself as wrong output
of SHOW OPEN TABLES statement (it was missing name-locked tables).
Finally in 5.1 both debug and non-debug versions simply crashed in
this situation due to NULL-pointer dereference.

This problem was caused by the fact that table placeholders which were
added to table cache in order to obtain name-lock had TABLE_SHARE::table_name
set to 0. Therefore they broke assumption that this member is non-0 for
all tables in table cache which was checked by assert in list_open_tables()
(in 5.1 this function simply relies on it).
The fix simply sets this member for such placeholders to appropriate value
making this assumption true again.

This patch also includes test for similar bug 12212 "Crash that happens
during removing of database name from cache" reappeared in 5.1 as bug 19403.
2006-08-21 12:18:59 +04:00
msvensson@neptunus.(none)
305dc01078 Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/bug11316/my50-bug11316
2005-09-01 17:15:37 +02:00
msvensson@neptunus.(none)
2fc6ef3a40 BUG#11316: mysqltest, problems when assigning value with '#' to $variable
- Add stricter checking of syntax in mysqltest
2005-08-31 17:16:05 +02:00
monty@mysql.com
3c12d0ae54 Added end marker for tests to make future merges easier 2005-07-28 03:22:47 +03:00
serg@serg.mylan
7ba99ee324 merged 2005-04-02 20:28:58 +02:00
serg@serg.mylan
3098b93ef8 bug#3891 - DROP TABLE many-unexistent-tables, was printing an error with %s instead of table names
sql/sql_table.cc: print an error with a function that respects width modifiers (%.64s)
2005-04-02 20:13:19 +02:00
monty@mysql.com
1bd22faa05 Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
This allows use to use INSERT IGNORE ... ON DUPLICATE ...
2004-12-31 12:04:35 +02:00
serg@serg.mylan
1c658417b1 make DROP DATABASE to behave as documented in the manual - to report number of files deleted 2004-03-18 11:03:24 +01:00
gluh@gluh.mysql.r18.ru
e4951147cf Fix for bug #799 FLUSH TABLES WITH READ LOCK does not block CREATE TABLE
This commit is related to my previos one(ChangeSet 1.1583 03/08/27 18:03:39).
Note about COMMIT&ROLLBACK:
  Only 'COMMIT' statement updates the binary log. 
  'ROLLBACK' statement doesn't update the binlog.
2003-08-28 18:09:00 +05:00
gluh@gluh.mysql.r18.ru
4c076ea6d7 Fix for bug #799 FLUSH TABLES WITH READ LOCK does not block CREATE TABLE 2003-08-27 18:03:39 +05:00
monty@mashka.mysql.fi
4f7512160b After merge fixes
Use server character set if --default-character-set is not used
Added convert_string() for more efficient alloc+character-set convert of strings
2003-08-19 00:08:08 +03:00
monty@mashka.mysql.fi
2263e3e51f Merge with 4.0.14 2003-08-11 22:44:43 +03:00
monty@narttu.mysql.fi
c21728f8c8 Cleaner implementation if INSERT ... SELECT with same tables
Tests cleanup (put drop database first in tests)
2003-07-03 11:55:36 +03:00
monty@mashka.mysql.fi
1f6ecc0cd3 Changed mysql-test to print warnings for not existing table to DROP TABLE
Cleaned up test; Removed wrong DROP TABLE commands and use standard table and database names.
changed store_warning() -> push_warning_print()
2003-01-06 01:48:59 +02:00
monty@hundin.mysql.fi
9e1ed2e4dc Fixed access privilege bug in query cache.
Change tests to use database 'mysqltest' instead of 'foo'
Add option to not print access denied messages to check_table_access()
2001-12-22 15:13:31 +02:00
monty@hundin.mysql.fi
67951fdeb4 Fix error messages
mysqltest now also writes failed error messages to log
2001-11-04 15:43:41 +02:00
monty@hundin.mysql.fi
0979515609 Fix error messages
Configure fixes
2001-09-18 05:16:39 +03:00
monty@hundin.mysql.fi
279de0c67c Update of manual with 4.0 changes
Create innodb table space if configuring with InnoDB and not using --skip-innodb
Fixes for TRUNCATE TABLE and DROP DATABASE.
2001-09-03 05:16:15 +03:00
sasha@mysql.sashanet.com
bd1500fc10 merged test from 4.0 2001-06-21 16:48:18 -06:00
sasha@mysql.sashanet.com
1e76c806eb fixed drop/create database bug when holding global read lock
preserve originating server id in Intvar events to avoid inifinite loops
2001-06-21 15:59:51 -06:00
sasha@mysql.sashanet.com
ee0f6217ea I was wrong about concurrent insert issue in rpl000016 - it still failed
once after the lock. Now changed test case and added eval support to
mysqltest to make it easier to debug
2001-03-27 10:23:04 -07:00