1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

fixes/cleanups according to Coverity report

This commit is contained in:
unknown
2005-01-24 15:48:25 +01:00
parent 3671fe1f72
commit 8bdb500105
29 changed files with 156 additions and 162 deletions

View File

@ -1157,12 +1157,12 @@ void Query_cache::invalidate(THD *thd, TABLE_LIST *tables_used,
DBUG_ASSERT(!using_transactions || tables_used->table!=0);
if (tables_used->derived)
continue;
if (using_transactions &&
(tables_used->table->file->table_cache_type() ==
if (using_transactions &&
(tables_used->table->file->table_cache_type() ==
HA_CACHE_TBL_TRANSACT))
/*
/*
Tables_used->table can't be 0 in transaction.
Only 'drop' invalidate not opened table, but 'drop'
Only 'drop' invalidate not opened table, but 'drop'
force transaction finish.
*/
thd->add_changed_table(tables_used->table);
@ -1210,7 +1210,7 @@ void Query_cache::invalidate(CHANGED_TABLE_LIST *tables_used)
*/
void Query_cache::invalidate_locked_for_write(TABLE_LIST *tables_used)
{
DBUG_ENTER("Query_cache::invalidate (changed table list)");
DBUG_ENTER("Query_cache::invalidate_locked_for_write");
if (query_cache_size > 0 && tables_used)
{
STRUCT_LOCK(&structure_guard_mutex);