1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

BUG#17138: Crash in stored procedure after fatal error that wasn't a real fatal error

This commit is contained in:
mikael@dator5.(none)
2006-06-20 16:52:40 -04:00
parent 75f3586117
commit 02e46e8204
3 changed files with 10 additions and 10 deletions

View File

@@ -9354,9 +9354,9 @@ bool create_myisam_from_heap(THD *thd, TABLE *table, TMP_TABLE_PARAM *param,
/* copy row that filled HEAP table */
if ((write_err=new_table.file->write_row(table->record[0])))
{
if (write_err != HA_ERR_FOUND_DUPP_KEY &&
write_err != HA_ERR_FOUND_DUPP_UNIQUE || !ignore_last_dupp_key_error)
goto err;
if (new_table.file->cannot_ignore_error(write_err, HA_CHECK_DUPP) ||
!ignore_last_dupp_key_error)
goto err;
}
/* remove heap table and change to use myisam table */
@@ -10777,8 +10777,7 @@ end_write(JOIN *join, JOIN_TAB *join_tab __attribute__((unused)),
join->found_records++;
if ((error=table->file->write_row(table->record[0])))
{
if (error == HA_ERR_FOUND_DUPP_KEY ||
error == HA_ERR_FOUND_DUPP_UNIQUE)
if (table->file->cannot_ignore_error(error, HA_CHECK_DUPP))
goto end;
if (create_myisam_from_heap(join->thd, table, &join->tmp_table_param,
error,1))