Commit e69c6e81 authored by Sergei Golubchik's avatar Sergei Golubchik

MDEV-9560 Mariadb 10.1 Crashes when replicating from 10.0

don't crash in debug builds. issue an error message on corrupt event
parent 96a7e74e
...@@ -11394,7 +11394,10 @@ Rows_log_event::write_row(rpl_group_info *rgi, ...@@ -11394,7 +11394,10 @@ Rows_log_event::write_row(rpl_group_info *rgi,
/* unpack row into table->record[0] */ /* unpack row into table->record[0] */
if ((error= unpack_current_row(rgi))) if ((error= unpack_current_row(rgi)))
{
table->file->print_error(error, MYF(0));
DBUG_RETURN(error); DBUG_RETURN(error);
}
if (m_curr_row == m_rows_buf && !invoke_triggers) if (m_curr_row == m_rows_buf && !invoke_triggers)
{ {
...@@ -12453,8 +12456,8 @@ Update_rows_log_event::do_exec_row(rpl_group_info *rgi) ...@@ -12453,8 +12456,8 @@ Update_rows_log_event::do_exec_row(rpl_group_info *rgi)
We need to read the second image in the event of error to be We need to read the second image in the event of error to be
able to skip to the next pair of updates able to skip to the next pair of updates
*/ */
m_curr_row= m_curr_row_end; if ((m_curr_row= m_curr_row_end))
unpack_current_row(rgi); unpack_current_row(rgi);
return error; return error;
} }
......
...@@ -185,7 +185,7 @@ pack_row(TABLE *table, MY_BITMAP const* cols, ...@@ -185,7 +185,7 @@ pack_row(TABLE *table, MY_BITMAP const* cols,
@retval HA_ERR_GENERIC @retval HA_ERR_GENERIC
A generic, internal, error caused the unpacking to fail. A generic, internal, error caused the unpacking to fail.
@retval ER_SLAVE_CORRUPT_EVENT @retval HA_ERR_CORRUPT_EVENT
Found error when trying to unpack fields. Found error when trying to unpack fields.
*/ */
#if !defined(MYSQL_CLIENT) && defined(HAVE_REPLICATION) #if !defined(MYSQL_CLIENT) && defined(HAVE_REPLICATION)
...@@ -322,7 +322,7 @@ unpack_row(rpl_group_info *rgi, ...@@ -322,7 +322,7 @@ unpack_row(rpl_group_info *rgi,
"Could not read field '%s' of table '%s.%s'", "Could not read field '%s' of table '%s.%s'",
f->field_name, table->s->db.str, f->field_name, table->s->db.str,
table->s->table_name.str); table->s->table_name.str);
DBUG_RETURN(ER_SLAVE_CORRUPT_EVENT); DBUG_RETURN(HA_ERR_CORRUPT_EVENT);
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment