1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Applying InnoDB snapshot, fixes BUG#41609.

Detailed revision comments:

r6252 | marko | 2009-11-30 12:50:11 +0200 (Mon, 30 Nov 2009) | 23 lines
branches/zip: Suppress errors about non-found temporary tables.
Write the is_temp flag to SYS_TABLES.MIX_LEN.

dict_table_t:🎏 Add a flag for is_temporary, DICT_TF2_TEMPORARY.
Unlike other flags, this will not be written to the tablespace flags
or SYS_TABLES.TYPE, but only to SYS_TABLES.MIX_LEN.

dict_build_table_def_step(): Only pass DICT_TF_BITS to tablespaces.

dict_check_tablespaces_and_store_max_id(), dict_load_table():
Suppress errors about temporary tables not being found.

dict_create_sys_tables_tuple(): Write the DICT_TF2_TEMPORARY flag
to SYS_TABLES.MIX_LEN.

fil_space_create(), fil_create_new_single_table_tablespace(): Add assertions
about space->flags.

row_drop_table_for_mysql(): Do not complain about non-found temporary tables.

rb://160 approved by Heikki Tuuri.  This addresses the second part of
Bug #41609 Crash recovery does not work for InnoDB temporary tables.
This commit is contained in:
Sergey Vojtovich
2010-04-01 14:45:58 +04:00
parent c29c9d93b0
commit 31143f1cf8
9 changed files with 143 additions and 50 deletions

View File

@ -3264,7 +3264,7 @@ check_next_foreign:
ut_error;
} else {
ibool is_path;
ibool is_temp;
const char* name_or_path;
mem_heap_t* heap;
@ -3277,12 +3277,13 @@ check_next_foreign:
space_id = table->space;
if (table->dir_path_of_temp_table != NULL) {
is_path = TRUE;
name_or_path = mem_heap_strdup(
heap, table->dir_path_of_temp_table);
is_temp = TRUE;
} else {
is_path = FALSE;
name_or_path = name;
is_temp = (table->flags >> DICT_TF2_SHIFT)
& DICT_TF2_TEMPORARY;
}
dict_table_remove_from_cache(table);
@ -3302,8 +3303,8 @@ check_next_foreign:
if (err == DB_SUCCESS && space_id > 0) {
if (!fil_space_for_table_exists_in_mem(space_id,
name_or_path,
is_path,
FALSE, TRUE)) {
is_temp, FALSE,
!is_temp)) {
err = DB_SUCCESS;
fprintf(stderr,