From c0b78cc47a2da2710cdf580ddbb3b31f5f691a23 Mon Sep 17 00:00:00 2001 From: Jon Olav Hauglid Date: Tue, 8 Dec 2009 15:38:58 +0100 Subject: Backport of revno: 2617.65.10 Bug #45067 Assertion `stmt_da->is_error()' in Delayed_insert::open_and_lock_table The assert was triggered when delayed insert was killed by another connection using mysql_notify_thread_having_shared_lock(). During handling of thd->killed, thd.fatal_error() was called without a previous call to my_error() which triggered the assert. This patch allows the assert to pass if thd->killed has been set. --- sql/sql_class.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sql/sql_class.h') diff --git a/sql/sql_class.h b/sql/sql_class.h index 67fa6306283..f4504bfed0d 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -2216,7 +2216,7 @@ public: */ inline void fatal_error() { - DBUG_ASSERT(main_da.is_error()); + DBUG_ASSERT(stmt_da->is_error() || killed); is_fatal_error= 1; DBUG_PRINT("error",("Fatal error set")); } -- cgit v1.2.1