diff options
Diffstat (limited to 'sql/sql_base.cc')
-rw-r--r-- | sql/sql_base.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/sql_base.cc b/sql/sql_base.cc index 01e8a65fda4..87d7f65fed5 100644 --- a/sql/sql_base.cc +++ b/sql/sql_base.cc @@ -2609,7 +2609,9 @@ void Locked_tables_list::mark_table_for_reopen(THD *thd, TABLE *table) bool Locked_tables_list::reopen_tables(THD *thd, bool need_reopen) { - Open_table_context ot_ctx(thd, MYSQL_OPEN_REOPEN); + bool is_ok= thd->get_stmt_da()->is_ok(); + Open_table_context ot_ctx(thd, !is_ok ? MYSQL_OPEN_REOPEN: + MYSQL_OPEN_IGNORE_KILLED | MYSQL_OPEN_REOPEN); uint reopen_count= 0; MYSQL_LOCK *lock; MYSQL_LOCK *merged_lock; |