mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Merge olga.mysql.com:/home/igor/mysql-5.0-opt
into olga.mysql.com:/home/igor/mysql-5.1-opt-merge
This commit is contained in:
@ -2226,6 +2226,7 @@ TABLE *open_table(THD *thd, TABLE_LIST *table_list, MEM_ROOT *mem_root,
|
||||
HASH_SEARCH_STATE state;
|
||||
DBUG_ENTER("open_table");
|
||||
|
||||
DBUG_ASSERT (table_list->lock_type != TL_WRITE_DEFAULT);
|
||||
/* find a unused table in the open table cache */
|
||||
if (refresh)
|
||||
*refresh=0;
|
||||
@ -3531,6 +3532,12 @@ int open_tables(THD *thd, TABLE_LIST **start, uint *counter, uint flags)
|
||||
for (tables= *start; tables ;tables= tables->next_global)
|
||||
{
|
||||
safe_to_ignore_table= FALSE; // 'FALSE', as per coding style
|
||||
|
||||
if (tables->lock_type == TL_WRITE_DEFAULT)
|
||||
{
|
||||
tables->lock_type= thd->update_lock_default;
|
||||
DBUG_ASSERT (tables->lock_type >= TL_WRITE_ALLOW_WRITE);
|
||||
}
|
||||
/*
|
||||
Ignore placeholders for derived tables. After derived tables
|
||||
processing, link to created temporary table will be put here.
|
||||
|
Reference in New Issue
Block a user