Commit f0f8795b authored by mats@mysql.com's avatar mats@mysql.com

Post-merge fixes.

parent a865af0d
...@@ -261,7 +261,7 @@ ndbcluster_binlog_open_table(THD *thd, NDB_SHARE *share, ...@@ -261,7 +261,7 @@ ndbcluster_binlog_open_table(THD *thd, NDB_SHARE *share,
my_free((gptr) table, MYF(0)); my_free((gptr) table, MYF(0));
DBUG_RETURN(error); DBUG_RETURN(error);
} }
assign_new_table_id(share); assign_new_table_id(table_share);
if (!table->record[1] || table->record[1] == table->record[0]) if (!table->record[1] || table->record[1] == table->record[0])
{ {
table->record[1]= alloc_root(&table->mem_root, table->record[1]= alloc_root(&table->mem_root,
......
...@@ -2414,11 +2414,17 @@ void abort_locked_tables(THD *thd,const char *db, const char *table_name) ...@@ -2414,11 +2414,17 @@ void abort_locked_tables(THD *thd,const char *db, const char *table_name)
share - Pointer to table share structure share - Pointer to table share structure
DESCRIPTION
We are intentionally not checking that share->mutex is locked
since this function should only be called when opening a table
share and before it is entered into the table_def_cache (meaning
that it cannot be fetched by another thread, even accidentally).
PRE-CONDITION(S) PRE-CONDITION(S)
share is non-NULL share is non-NULL
The LOCK_open mutex is locked The LOCK_open mutex is locked
The share->mutex is locked
POST-CONDITION(S) POST-CONDITION(S)
...@@ -2438,7 +2444,6 @@ void assign_new_table_id(TABLE_SHARE *share) ...@@ -2438,7 +2444,6 @@ void assign_new_table_id(TABLE_SHARE *share)
/* Preconditions */ /* Preconditions */
DBUG_ASSERT(share != NULL); DBUG_ASSERT(share != NULL);
safe_mutex_assert_owner(&LOCK_open); safe_mutex_assert_owner(&LOCK_open);
safe_mutex_assert_owner(&share->mutex);
ulong tid= ++last_table_id; /* get next id */ ulong tid= ++last_table_id; /* get next id */
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment