mirror of
https://github.com/MariaDB/server.git
synced 2025-01-29 18:20:07 +01:00
InnoDB: Fix assertion failure for orphaned tables in DROP DATABASE
This commit is contained in:
parent
dd9a517e53
commit
d48d5681c8
1 changed files with 3 additions and 2 deletions
|
@ -2208,10 +2208,11 @@ row_drop_database_for_mysql(
|
|||
dict_table_t* table;
|
||||
char* table_name;
|
||||
int err = DB_SUCCESS;
|
||||
ulint namelen = strlen(name);
|
||||
|
||||
ut_ad(trx->mysql_thread_id == os_thread_get_curr_id());
|
||||
ut_a(name != NULL);
|
||||
ut_a(name[strlen(name) - 1] == '/');
|
||||
ut_a(name[namelen - 1] == '/');
|
||||
|
||||
trx->op_info = (char *) "dropping database";
|
||||
|
||||
|
@ -2220,7 +2221,7 @@ loop:
|
|||
row_mysql_lock_data_dictionary(trx);
|
||||
|
||||
while ((table_name = dict_get_first_table_name_in_db(name))) {
|
||||
ut_a(strcmp(table_name, name) == 0);
|
||||
ut_a(memcmp(table_name, name, namelen) == 0);
|
||||
|
||||
table = dict_table_get_low(table_name);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue