summaryrefslogtreecommitdiff
path: root/sql/sql_insert.cc
diff options
context:
space:
mode:
authorDavi Arnaut <Davi.Arnaut@Sun.COM>2009-11-19 21:48:08 -0200
committerDavi Arnaut <Davi.Arnaut@Sun.COM>2009-11-19 21:48:08 -0200
commit5aeeaaf507ac87f6ff56806fe8a356cea7d4a48f (patch)
treed21225ac09b301f317ca89093128769a5ede9fbb /sql/sql_insert.cc
parent780871d8b90fe3146db39b4be65ebedb309b9f9b (diff)
parent5128b54c38ae183d18a29e00b318c22046445715 (diff)
downloadmariadb-git-5aeeaaf507ac87f6ff56806fe8a356cea7d4a48f.tar.gz
Manual merge of mysql-next-mr-runtime upstream.
Diffstat (limited to 'sql/sql_insert.cc')
-rw-r--r--sql/sql_insert.cc14
1 files changed, 5 insertions, 9 deletions
diff --git a/sql/sql_insert.cc b/sql/sql_insert.cc
index 173e7f1ca2f..b1c7c7f647e 100644
--- a/sql/sql_insert.cc
+++ b/sql/sql_insert.cc
@@ -1922,20 +1922,17 @@ bool delayed_get_table(THD *thd, TABLE_LIST *table_list)
if (! (di= find_handler(thd, table_list)))
{
if (!(di= new Delayed_insert()))
- {
- thd->fatal_error();
goto end_create;
- }
pthread_mutex_lock(&LOCK_thread_count);
thread_count++;
pthread_mutex_unlock(&LOCK_thread_count);
di->thd.set_db(table_list->db, (uint) strlen(table_list->db));
- di->thd.set_query(my_strdup(table_list->table_name, MYF(MY_WME)), 0);
+ di->thd.set_query(my_strdup(table_list->table_name,
+ MYF(MY_WME | ME_FATALERROR)), 0);
if (di->thd.db == NULL || di->thd.query() == NULL)
{
/* The error is reported */
delete di;
- thd->fatal_error();
goto end_create;
}
di->table_list= *table_list; // Needed to open table
@@ -1953,8 +1950,7 @@ bool delayed_get_table(THD *thd, TABLE_LIST *table_list)
pthread_mutex_unlock(&di->mutex);
di->unlock();
delete di;
- my_error(ER_CANT_CREATE_THREAD, MYF(0), error);
- thd->fatal_error();
+ my_error(ER_CANT_CREATE_THREAD, MYF(ME_FATALERROR), error);
goto end_create;
}
@@ -2331,8 +2327,8 @@ static void handle_delayed_insert_impl(THD *thd, Delayed_insert *di)
}
if (!(di->table->file->ha_table_flags() & HA_CAN_INSERT_DELAYED))
{
- thd->fatal_error();
- my_error(ER_DELAYED_NOT_SUPPORTED, MYF(0), di->table_list.table_name);
+ my_error(ER_DELAYED_NOT_SUPPORTED, MYF(ME_FATALERROR),
+ di->table_list.table_name);
goto err;
}
if (di->table->triggers)