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.
This commit is contained in:
Jon Olav Hauglid 2009-12-08 15:38:58 +01:00
parent c20afa6d49
commit f28f985922

View file

@ -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"));
}