From 214c43ba96d806629e24818099edf45e7cabdd66 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Mon, 26 Aug 2013 21:14:34 +0400 Subject: [PATCH] bugfix: storage engine might return a negative error code, but it shouldn't be ignored on return --- sql/sql_table.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sql/sql_table.cc b/sql/sql_table.cc index 9d0b7b709c9..97a2ef03757 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -7531,11 +7531,13 @@ copy_data_between_tables(THD *thd, TABLE *from,TABLE *to, AUTO_INCREMENT_FLAG)) err_msg= ER(ER_DUP_ENTRY_AUTOINCREMENT_CASE); to->file->print_keydup_error(key_nr, err_msg, MYF(0)); + error= 1; break; } } to->file->print_error(error,MYF(0)); + error= 1; break; } to->file->restore_auto_increment(prev_insert_id);